]> diplodocus.org Git - nmh/blobdiff - sbr/lock_file.c
Removed a bunch of unreachable break statements found by
[nmh] / sbr / lock_file.c
index 079f089640788f8ba6556e8c68140ed3941fdf1f..01d7ae49a849e4710c46ca7942334dfc05d2de54 100644 (file)
 #ifdef HAVE_FLOCK
 # include <sys/file.h>
 #endif
-#ifdef HAVE_LOCKF
-# include <unistd.h>
-#endif
-
-#include <signal.h>
 
 #if defined(HAVE_LIBLOCKFILE)
-#include <lockfile.h>
+# include <lockfile.h>
 #endif
 
 #ifdef LOCKDIR
@@ -385,6 +380,7 @@ lkopen_fcntl(const char *file, int access, mode_t mode)
 }
 
 
+#ifdef HAVE_FLOCK
 /*
  * Open and lock a file, using flock locking
  */
@@ -417,7 +413,7 @@ lkopen_flock(const char *file, int access, mode_t mode)
     errno = saved_errno;
     return -1;
 }
-
+#endif /* HAVE_FLOCK */
 
 /*
  * Open and lock a file, using lockf locking