svn commit: r216750 - stable/8/usr.bin/find

Kevin Lo kevlo at FreeBSD.org
Tue Dec 28 02:25:32 UTC 2010


Author: kevlo
Date: Tue Dec 28 02:25:32 2010
New Revision: 216750
URL: http://svn.freebsd.org/changeset/base/216750

Log:
  MFC r216106:
  Don't error out while searching for empty directories.
  
  Submitted by:	Bakul Shah <bakul at bitblocks dot com>

Modified:
  stable/8/usr.bin/find/function.c

Modified: stable/8/usr.bin/find/function.c
==============================================================================
--- stable/8/usr.bin/find/function.c	Tue Dec 28 01:38:52 2010	(r216749)
+++ stable/8/usr.bin/find/function.c	Tue Dec 28 02:25:32 2010	(r216750)
@@ -560,7 +560,7 @@ f_empty(PLAN *plan __unused, FTSENT *ent
 		empty = 1;
 		dir = opendir(entry->fts_accpath);
 		if (dir == NULL)
-			err(1, "%s", entry->fts_accpath);
+			return 0;
 		for (dp = readdir(dir); dp; dp = readdir(dir))
 			if (dp->d_name[0] != '.' ||
 			    (dp->d_name[1] != '\0' &&


More information about the svn-src-stable-8 mailing list