From owner-svn-src-all@FreeBSD.ORG Thu Dec 2 01:46:06 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A07D1065679; Thu, 2 Dec 2010 01:46:06 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 88B0C8FC0A; Thu, 2 Dec 2010 01:46:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id oB21k6M8066822; Thu, 2 Dec 2010 01:46:06 GMT (envelope-from kevlo@svn.freebsd.org) Received: (from kevlo@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id oB21k6RI066820; Thu, 2 Dec 2010 01:46:06 GMT (envelope-from kevlo@svn.freebsd.org) Message-Id: <201012020146.oB21k6RI066820@svn.freebsd.org> From: Kevin Lo Date: Thu, 2 Dec 2010 01:46:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216106 - head/usr.bin/find X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2010 01:46:06 -0000 Author: kevlo Date: Thu Dec 2 01:46:06 2010 New Revision: 216106 URL: http://svn.freebsd.org/changeset/base/216106 Log: Don't error out while searching for empty directories. Submitted by: Bakul Shah Modified: head/usr.bin/find/function.c Modified: head/usr.bin/find/function.c ============================================================================== --- head/usr.bin/find/function.c Thu Dec 2 01:36:00 2010 (r216105) +++ head/usr.bin/find/function.c Thu Dec 2 01:46:06 2010 (r216106) @@ -559,7 +559,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' &&