Move the warning msg after features.h gets pulled in.
[oweals/busybox.git] / sync.c
diff --git a/sync.c b/sync.c
index db35d72faec2aacb8e5f1b924e4a13c5714d3454..ee22ae109c5a222dd29a958ef375138f54e4220e 100644 (file)
--- a/sync.c
+++ b/sync.c
  *
  */
 
-#include "internal.h"
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include "busybox.h"
 
 extern int sync_main(int argc, char **argv)
 {
-       if (argc > 1 && **(argv + 1) == '-') {
-               usage("sync\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
-                               "\nWrite all buffered filesystem blocks to disk.\n"
-#endif
-                               );
-       }
-       return(sync());
+       if (argc > 1 && **(argv + 1) == '-')
+               show_usage();
+       sync();
+       return(EXIT_SUCCESS);
 }