dd: code shrink
[oweals/busybox.git] / util-linux / flock.c
index 8fecb54d4b4df8484af747da6f79c5bfb76a1953..05a747f724b678a0bc6cfeca032f4f42ad4b2783 100644 (file)
@@ -8,7 +8,6 @@
 //usage:       "[-sxun] FD|{FILE [-c] PROG ARGS}"
 //usage:#define flock_full_usage "\n\n"
 //usage:       "[Un]lock file descriptor, or lock FILE, run PROG\n"
-//usage:     "\nOptions:"
 //usage:     "\n       -s      Shared lock"
 //usage:     "\n       -x      Exclusive lock (default)"
 //usage:     "\n       -u      Unlock FD"
@@ -46,7 +45,7 @@ int flock_main(int argc UNUSED_PARAM, char **argv)
        if (argv[1]) {
                fd = open(argv[0], O_RDONLY|O_NOCTTY|O_CREAT, 0666);
                if (fd < 0 && errno == EISDIR)
-                       fd = open(argv[0], O_RDONLY|O_NOCTTY);
+                       fd = open(argv[0], O_RDONLY|O_NOCTTY);
                if (fd < 0)
                        bb_perror_msg_and_die("can't open '%s'", argv[0]);
                //TODO? close_on_exec_on(fd);