* lib/xstrtol.h: Include gettext.h.
[gnulib.git] / lib / savewd.c
index 7e99237..625c3cd 100644 (file)
@@ -25,6 +25,7 @@
 #include <assert.h>
 #include <errno.h>
 #include <fcntl.h>
+#include <signal.h>
 #include <stdbool.h>
 #include <sys/types.h>
 #include <sys/wait.h>
@@ -102,7 +103,8 @@ savewd_chdir (struct savewd *wd, char const *dir, int options,
 
   /* Open the directory if requested, or if avoiding a race condition
      is requested and possible.  */
-  if (open_result || (options & (O_NOFOLLOW ? SAVEWD_CHDIR_NOFOLLOW : 0)))
+  if (open_result
+      || (options & (HAVE_WORKING_O_NOFOLLOW ? SAVEWD_CHDIR_NOFOLLOW : 0)))
     {
       fd = open (dir,
                 (O_RDONLY | O_DIRECTORY | O_NOCTTY | O_NONBLOCK