findutils-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Findutils-patches] [PATCH 10/19] find: avoid using undefined statbuf


From: James Youngman
Subject: [Findutils-patches] [PATCH 10/19] find: avoid using undefined statbuf
Date: Fri, 10 Apr 2009 23:53:07 +0100

From: Jim Meyering <address@hidden>

* find/ftsfind.c (consider_visiting): Use local variable, mode,
rather than possibly undefined statbuf.st_mode.
(cherry picked from commit f4d8c73d0bc493c07da291e2587192113270d319)
---
 find/ftsfind.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/find/ftsfind.c b/find/ftsfind.c
index 1fc5459..b59d896 100644
--- a/find/ftsfind.c
+++ b/find/ftsfind.c
@@ -498,7 +498,7 @@ consider_visiting(FTS *p, FTSENT *ent)
 
   /* examine this item. */
   ignore = 0;
-  isdir = S_ISDIR(statbuf.st_mode)
+  isdir = S_ISDIR(mode)
     || (FTS_D  == ent->fts_info)
     || (FTS_DP == ent->fts_info)
     || (FTS_DC == ent->fts_info);
-- 
1.5.6.5





reply via email to

[Prev in Thread] Current Thread [Next in Thread]