Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Apr 2006 21:04:38 GMT
From:      Peter Wemm <peter@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 94559 for review
Message-ID:  <200604032104.k33L4cux060462@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=94559

Change 94559 by peter@peter_melody on 2006/04/03 21:04:11

	IFC @94558

Affected files ...

.. //depot/projects/hammer/ObsoleteFiles.inc#17 integrate
.. //depot/projects/hammer/sys/kern/subr_kdb.c#17 integrate
.. //depot/projects/hammer/tools/build/mk/OptionalObsoleteFiles.inc#1 branch
.. //depot/projects/hammer/usr.bin/find/find.1#17 integrate
.. //depot/projects/hammer/usr.bin/find/find.h#3 integrate
.. //depot/projects/hammer/usr.bin/find/function.c#9 integrate
.. //depot/projects/hammer/usr.bin/find/option.c#8 integrate

Differences ...

==== //depot/projects/hammer/ObsoleteFiles.inc#17 (text+ko) ====

@@ -1,5 +1,5 @@
 #
-# $FreeBSD: src/ObsoleteFiles.inc,v 1.31 2006/03/28 18:28:33 simon Exp $
+# $FreeBSD: src/ObsoleteFiles.inc,v 1.32 2006/04/03 18:42:43 netchild Exp $
 #
 # This file lists old files (OLD_FILES), libraries (OLD_LIBS) and
 # directories (OLD_DIRS) which should get removed at an update. Recently
@@ -2877,3 +2877,4 @@
 OLD_DIRS+=usr/share/doc/bind/misc
 OLD_DIRS+=usr/share/doc/bind/
 
+.include "tools/build/mk/OptionalObsoleteFiles.inc"

==== //depot/projects/hammer/sys/kern/subr_kdb.c#17 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/subr_kdb.c,v 1.18 2006/04/03 17:48:09 marcel Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/subr_kdb.c,v 1.19 2006/04/03 20:55:52 marcel Exp $");
 
 #include "opt_kdb.h"
 
@@ -453,10 +453,11 @@
 int
 kdb_trap(int type, int code, struct trapframe *tf)
 {
+	register_t intr;
 #ifdef SMP
 	int did_stop_cpus;
 #endif
-	int handled, intr;
+	int handled;
 
 	if (kdb_dbbe == NULL || kdb_dbbe->dbbe_trap == NULL)
 		return (0);

==== //depot/projects/hammer/usr.bin/find/find.1#17 (text+ko) ====

@@ -33,7 +33,7 @@
 .\" SUCH DAMAGE.
 .\"
 .\"	@(#)find.1	8.7 (Berkeley) 5/9/95
-.\" $FreeBSD: src/usr.bin/find/find.1,v 1.73 2005/06/14 11:50:51 ru Exp $
+.\" $FreeBSD: src/usr.bin/find/find.1,v 1.74 2006/04/03 20:36:37 ceri Exp $
 .\"
 .Dd April 2, 2005
 .Dt FIND 1
@@ -174,6 +174,35 @@
 .El
 .Sh PRIMARIES
 .Bl -tag -width indent
+.It Ic -Bmin Ar n
+True if the difference between the time of a file's inode creation
+and the time
+.Nm
+was started, rounded up to the next full minute, is
+.Ar n
+minutes.
+.It Ic -Bnewer Ar file
+Same as
+.Ic -newerBm .
+.It Ic -Btime Ar n Ns Op Cm smhdw
+If no units are specified, this primary evaluates to
+true if the difference between the time of a file's inode creation
+and the time
+.Nm
+was started, rounded up to the next full 24-hour period, is
+.Ar n
+24-hour periods.
+.Pp
+If units are specified, this primary evaluates to
+true if the difference between the time of last change of file status
+information and the time
+.Nm
+was started is exactly
+.Ar n
+units.
+Please refer to the
+.Ic -atime
+primary description for information on supported time units.
 .It Ic -acl
 May be used in conjunction with other options to locate
 files with extended ACLs.
@@ -497,12 +526,16 @@
 .It Ic -newer Ns Ar X Ns Ar Y Ar file
 True if the current file has a more recent last access time
 .Ar ( X Ns = Ns Cm a ) ,
+inode creation time
+.Ar ( X Ns = Ns Cm B ) ,
 change time
 .Ar ( X Ns = Ns Cm c ) ,
 or modification time
 .Ar ( X Ns = Ns Cm m )
 than the last access time
 .Ar ( Y Ns = Ns Cm a ) ,
+inode creation time
+.Ar ( Y Ns = Ns Cm B ) ,
 change time
 .Ar ( Y Ns = Ns Cm c ) ,
 or modification time

==== //depot/projects/hammer/usr.bin/find/find.h#3 (text+ko) ====

@@ -34,7 +34,7 @@
  * SUCH DAMAGE.
  *
  *	@(#)find.h	8.1 (Berkeley) 6/6/93
- *	$FreeBSD: src/usr.bin/find/find.h,v 1.17 2004/05/28 17:17:15 eik Exp $
+ *	$FreeBSD: src/usr.bin/find/find.h,v 1.18 2006/04/03 20:36:37 ceri Exp $
  */
 
 #include <regex.h>
@@ -72,6 +72,8 @@
 #define	F_IGNCASE	0x00010000	/* iname ipath iregex */
 #define	F_EXACTTIME	F_IGNCASE	/* -[acm]time units syntax */
 #define F_EXECPLUS	0x00020000	/* -exec ... {} + */
+#define	F_TIME_B	0x00040000	/* one of -Btime, -Bnewer, -newerB* */
+#define	F_TIME2_B	0x00080000	/* one of -newer?B */
 
 /* node definition */
 typedef struct _plandata {

==== //depot/projects/hammer/usr.bin/find/function.c#9 (text+ko) ====

@@ -41,7 +41,7 @@
 #endif /* not lint */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/usr.bin/find/function.c,v 1.54 2005/08/25 13:44:02 roberto Exp $");
+__FBSDID("$FreeBSD: src/usr.bin/find/function.c,v 1.55 2006/04/03 20:36:37 ceri Exp $");
 
 #include <sys/param.h>
 #include <sys/ucred.h>
@@ -234,10 +234,10 @@
 } /* nextarg() */
 
 /*
- * The value of n for the inode times (atime, ctime, and mtime) is a range,
- * i.e. n matches from (n - 1) to n 24 hour periods.  This interacts with
- * -n, such that "-mtime -1" would be less than 0 days, which isn't what the
- * user wanted.  Correct so that -1 is "less than 1".
+ * The value of n for the inode times (atime, birthtime, ctime, mtime) is a
+ * range, i.e. n matches from (n - 1) to n 24 hour periods.  This interacts
+ * with -n, such that "-mtime -1" would be less than 0 days, which isn't what
+ * the user wanted.  Correct so that -1 is "less than 1".
  */
 #define	TIME_CORRECT(p) \
 	if (((p)->flags & F_ELG_MASK) == F_LESSTHAN) \
@@ -248,6 +248,7 @@
  *
  *    True if the difference between the
  *		file access time (-amin)
+ *		file birth time (-Bmin)
  *		last change of file status information (-cmin)
  *		file modification time (-mmin)
  *    and the current time is n min periods.
@@ -261,6 +262,9 @@
 	} else if (plan->flags & F_TIME_A) {
 		COMPARE((now - entry->fts_statp->st_atime +
 		    60 - 1) / 60, plan->t_data);
+	} else if (plan->flags & F_TIME_B) {
+		COMPARE((now - entry->fts_statp->st_birthtime +
+		    60 - 1) / 60, plan->t_data);
 	} else {
 		COMPARE((now - entry->fts_statp->st_mtime +
 		    60 - 1) / 60, plan->t_data);
@@ -287,6 +291,7 @@
  *
  *	True if the difference between the
  *		file access time (-atime)
+ *		file birth time (-Btime)
  *		last change of file status information (-ctime)
  *		file modification time (-mtime)
  *	and the current time is n 24 hour periods.
@@ -299,6 +304,8 @@
 
 	if (plan->flags & F_TIME_A)
 		xtime = entry->fts_statp->st_atime;
+	else if (plan->flags & F_TIME_B)
+		xtime = entry->fts_statp->st_birthtime;
 	else if (plan->flags & F_TIME_C)
 		xtime = entry->fts_statp->st_ctime;
 	else
@@ -1065,6 +1072,8 @@
 		return entry->fts_statp->st_ctime > plan->t_data;
 	else if (plan->flags & F_TIME_A)
 		return entry->fts_statp->st_atime > plan->t_data;
+	else if (plan->flags & F_TIME_B)
+		return entry->fts_statp->st_birthtime > plan->t_data;
 	else
 		return entry->fts_statp->st_mtime > plan->t_data;
 }

==== //depot/projects/hammer/usr.bin/find/option.c#8 (text+ko) ====

@@ -41,7 +41,7 @@
 #endif /* not lint */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/usr.bin/find/option.c,v 1.23 2004/07/29 03:29:44 tjr Exp $");
+__FBSDID("$FreeBSD: src/usr.bin/find/option.c,v 1.24 2006/04/03 20:36:37 ceri Exp $");
 
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -68,6 +68,9 @@
 	{ "-and",	c_and,		NULL,		0 },
 	{ "-anewer",	c_newer,	f_newer,	F_TIME_A },
 	{ "-atime",	c_Xtime,	f_Xtime,	F_TIME_A },
+	{ "-Bmin",	c_Xmin,		f_Xmin,		F_TIME_B },
+	{ "-Bnewer",	c_newer,	f_newer,	F_TIME_B },
+	{ "-Btime",	c_Xtime,	f_Xtime,	F_TIME_B },
 	{ "-cmin",	c_Xmin,		f_Xmin,		F_TIME_C },
 	{ "-cnewer",	c_newer,	f_newer,	F_TIME_C },
 	{ "-ctime",	c_Xtime,	f_Xtime,	F_TIME_C },
@@ -95,14 +98,22 @@
 	{ "-name",	c_name,		f_name,		0 },
 	{ "-newer",	c_newer,	f_newer,	0 },
 	{ "-neweraa",	c_newer,	f_newer,	F_TIME_A | F_TIME2_A },
+	{ "-neweraB",	c_newer,	f_newer,	F_TIME_A | F_TIME2_B },
 	{ "-newerac",	c_newer,	f_newer,	F_TIME_A | F_TIME2_C },
 	{ "-neweram",	c_newer,	f_newer,	F_TIME_A },
 	{ "-newerat",	c_newer,	f_newer,	F_TIME_A | F_TIME2_T },
+	{ "-newerBa",	c_newer,	f_newer,	F_TIME_B | F_TIME2_A },
+	{ "-newerBB",	c_newer,	f_newer,	F_TIME_B | F_TIME2_B },
+	{ "-newerBc",	c_newer,	f_newer,	F_TIME_B | F_TIME2_C },
+	{ "-newerBm",	c_newer,	f_newer,	F_TIME_B },
+	{ "-newerBt",	c_newer,	f_newer,	F_TIME_B | F_TIME2_T },
 	{ "-newerca",	c_newer,	f_newer,	F_TIME_C | F_TIME2_A },
+	{ "-newercB",	c_newer,	f_newer,	F_TIME_C | F_TIME2_B },
 	{ "-newercc",	c_newer,	f_newer,	F_TIME_C | F_TIME2_C },
 	{ "-newercm",	c_newer,	f_newer,	F_TIME_C },
 	{ "-newerct",	c_newer,	f_newer,	F_TIME_C | F_TIME2_T },
 	{ "-newerma",	c_newer,	f_newer,	F_TIME2_A },
+	{ "-newermB",	c_newer,	f_newer,	F_TIME2_B },
 	{ "-newermc",	c_newer,	f_newer,	F_TIME2_C },
 	{ "-newermm",	c_newer,	f_newer,	0 },
 	{ "-newermt",	c_newer,	f_newer,	F_TIME2_T },



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200604032104.k33L4cux060462>