usage.c: remove reference to busybox.h
[oweals/busybox.git] / coreutils / watch.c
index b188b41764aad64c54844e352cee08b7cbae1620..2ad0564cd7c226d44d3396a699471b9160186d53 100644 (file)
@@ -11,7 +11,7 @@
 /* BB_AUDIT SUSv3 N/A */
 /* BB_AUDIT GNU defects -- only option -n is supported. */
 
-#include "busybox.h"
+#include "libbb.h"
 
 // procps 2.0.18:
 // watch [-d] [-n seconds]
@@ -23,6 +23,7 @@
 //
 // (procps 3.x and procps 2.x are forks, not newer/older versions of the same)
 
+int watch_main(int argc, char **argv);
 int watch_main(int argc, char **argv)
 {
        unsigned opt;
@@ -58,7 +59,6 @@ int watch_main(int argc, char **argv)
                        time_t t;
 
                        get_terminal_width_height(STDOUT_FILENO, &width, 0);
-                       if (width < 1) width = 1; // paranoia
                        header = xrealloc(header, width--);
                        // '%-*s' pads header with spaces to the full width
                        snprintf(header, width, "Every %ds: %-*s", period, width, cmd);