A small cleanup by Vladimir
[oweals/busybox.git] / sync.c
diff --git a/sync.c b/sync.c
index f8160c8dcb42e1fdbd1067a3668c95dadd5564d6..3d4686efaef006ea3e4405263f8e4bbd3332ad1a 100644 (file)
--- a/sync.c
+++ b/sync.c
  *
  */
 
-#include "internal.h"
+#include "busybox.h"
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 
 extern int sync_main(int argc, char **argv)
 {
-       if (argc > 1 && **(argv + 1) == '-') {
-               usage("sync\n\nWrite all buffered filesystem blocks to disk.\n");
-       }
-       exit(sync());
+       if (argc > 1 && **(argv + 1) == '-')
+               show_usage();
+       sync();
+       return(EXIT_SUCCESS);
 }