summaryrefslogtreecommitdiff
blob: f38c070ef1e099c5eacd7e0479b368ecf56313c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
--- findutils-4.2.18/find/find.c.az	2005-02-20 19:09:47 +0200
+++ findutils-4.2.18/find/find.c	2005-02-20 19:10:04 +0200
@@ -1092,9 +1092,10 @@ safely_chdir_nofollow(const char *dest,
 		      enum ChdirSymlinkHandling symlink_handling)
 {
   int extraflags = following_links() ? O_NOFOLLOW : 0;
+  int fd = 0;
 
   errno = 0;
-  int fd = open(dest, O_RDONLY|extraflags);
+  fd = open(dest, O_RDONLY|extraflags);
   if (fd < 0)
     {
       switch (errno)