projects
/
oweals
/
busybox.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
stty: sort out preprocessor conditionals
[oweals/busybox.git]
/
coreutils
/
hostid.c
diff --git
a/coreutils/hostid.c
b/coreutils/hostid.c
index cda96726ab0775239592eb27b187c3e227c41e94..a537e3ad6eb9c53781147c6ffd0d4e72fc0f2ee0 100644
(file)
--- a/
coreutils/hostid.c
+++ b/
coreutils/hostid.c
@@
-9,17
+9,18
@@
/* BB_AUDIT SUSv3 N/A -- Matches GNU behavior. */
/* BB_AUDIT SUSv3 N/A -- Matches GNU behavior. */
-#include <stdlib.h>
-#include <unistd.h>
-#include "busybox.h"
+#include "libbb.h"
-int hostid_main(int argc, char ATTRIBUTE_UNUSED **argv)
+/* This is a NOFORK applet. Be very careful! */
+
+int hostid_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
+int hostid_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
{
{
- if (arg
c > 1
) {
+ if (arg
v[1]
) {
bb_show_usage();
}
bb_show_usage();
}
-
bb_
printf("%lx\n", gethostid());
+ printf("%lx\n", gethostid());
-
bb_fflush_stdout_and_exit(EXIT_SUCCESS
);
+
return fflush_all(
);
}
}