]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
BZ#18921: Fix opendir inverted o_directory_works test.
authorRoland McGrath <roland@hack.frob.com>
Fri, 4 Sep 2015 21:37:56 +0000 (14:37 -0700)
committerMike Frysinger <vapier@gentoo.org>
Sun, 11 Oct 2015 00:03:27 +0000 (20:03 -0400)
(cherry picked from commit bd9e69abb887d78d0d6708fc089cc9f3eabf106d)
(cherry picked from commit 5c8c3123652045191474a4ca85fbb6e8d9e7d2bc)

sysdeps/posix/opendir.c

index 6509f5c05cd4319fa7f4148475eaa6fd8af61b20..9edf056fb30f433f90fa6e7971668247d3766cc7 100644 (file)
@@ -105,7 +105,7 @@ need_isdir_precheck (void)
     tryopen_o_directory ();
 
   /* We can skip the expensive `stat' call if O_DIRECTORY works.  */
-  return o_directory_works > 0;
+  return o_directory_works < 0;
 #endif
   return true;
 }