diff options
| author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-03-17 09:00:54 +0000 |
|---|---|---|
| committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-03-17 09:00:54 +0000 |
| commit | 68404f13d4bf4826e3609703dad5375763db28ab (patch) | |
| tree | b89ed41daeb3a761ac9416a6eed090023b23e7e2 /util-linux | |
| parent | a55bd05f3cea6c7cbfb45d15009cb70570c2a43b (diff) | |
| download | busybox-w32-68404f13d4bf4826e3609703dad5375763db28ab.tar.gz busybox-w32-68404f13d4bf4826e3609703dad5375763db28ab.tar.bz2 busybox-w32-68404f13d4bf4826e3609703dad5375763db28ab.zip | |
*: add -Wunused-parameter; fix resulting breakage
function old new delta
procps_scan 1265 1298 +33
aliascmd 278 283 +5
parse_file_cmd 116 120 +4
dname_enc 373 377 +4
setcmd 90 93 +3
execcmd 57 60 +3
count_lines 72 74 +2
process_command_subs 340 339 -1
test_main 409 407 -2
mknod_main 179 177 -2
handle_incoming_and_exit 2653 2651 -2
argstr 1312 1310 -2
shiftcmd 131 128 -3
exitcmd 46 43 -3
dotcmd 297 294 -3
breakcmd 86 83 -3
evalpipe 353 349 -4
evalcommand 1180 1176 -4
evalcmd 109 105 -4
send_tree 374 369 -5
mkfifo_main 82 77 -5
evalsubshell 152 147 -5
typecmd 75 69 -6
letcmd 61 55 -6
add_cmd 1190 1183 -7
main 891 883 -8
ash_main 1415 1407 -8
parse_stream 1377 1367 -10
alloc_procps_scan 55 - -55
------------------------------------------------------------------------------
(add/remove: 0/1 grow/shrink: 7/21 up/down: 54/-148) Total: -94 bytes
text data bss dec hex filename
797195 658 7428 805281 c49a1 busybox_old
797101 658 7428 805187 c4943 busybox_unstripped
Diffstat (limited to 'util-linux')
| -rw-r--r-- | util-linux/dmesg.c | 2 | ||||
| -rw-r--r-- | util-linux/fsck_minix.c | 2 | ||||
| -rw-r--r-- | util-linux/hwclock.c | 2 | ||||
| -rw-r--r-- | util-linux/ipcs.c | 2 | ||||
| -rw-r--r-- | util-linux/mdev.c | 12 | ||||
| -rw-r--r-- | util-linux/mkfs_minix.c | 4 | ||||
| -rw-r--r-- | util-linux/more.c | 4 | ||||
| -rw-r--r-- | util-linux/mount.c | 2 | ||||
| -rw-r--r-- | util-linux/rdate.c | 4 | ||||
| -rw-r--r-- | util-linux/readprofile.c | 2 | ||||
| -rw-r--r-- | util-linux/rtcwake.c | 2 | ||||
| -rw-r--r-- | util-linux/script.c | 6 | ||||
| -rw-r--r-- | util-linux/switch_root.c | 2 | ||||
| -rw-r--r-- | util-linux/umount.c | 2 |
14 files changed, 26 insertions, 22 deletions
diff --git a/util-linux/dmesg.c b/util-linux/dmesg.c index cdd385ede..9e834ffd3 100644 --- a/util-linux/dmesg.c +++ b/util-linux/dmesg.c | |||
| @@ -13,7 +13,7 @@ | |||
| 13 | #include "libbb.h" | 13 | #include "libbb.h" |
| 14 | 14 | ||
| 15 | int dmesg_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 15 | int dmesg_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 16 | int dmesg_main(int argc, char **argv) | 16 | int dmesg_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 17 | { | 17 | { |
| 18 | int len; | 18 | int len; |
| 19 | char *buf; | 19 | char *buf; |
diff --git a/util-linux/fsck_minix.c b/util-linux/fsck_minix.c index 63f915ac5..058e8bed7 100644 --- a/util-linux/fsck_minix.c +++ b/util-linux/fsck_minix.c | |||
| @@ -1204,7 +1204,7 @@ void check2(void); | |||
| 1204 | #endif | 1204 | #endif |
| 1205 | 1205 | ||
| 1206 | int fsck_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 1206 | int fsck_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 1207 | int fsck_minix_main(int argc, char **argv) | 1207 | int fsck_minix_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 1208 | { | 1208 | { |
| 1209 | struct termios tmp; | 1209 | struct termios tmp; |
| 1210 | int retcode = 0; | 1210 | int retcode = 0; |
diff --git a/util-linux/hwclock.c b/util-linux/hwclock.c index f226535fa..44522dfd7 100644 --- a/util-linux/hwclock.c +++ b/util-linux/hwclock.c | |||
| @@ -91,7 +91,7 @@ static void from_sys_clock(int utc) | |||
| 91 | #define HWCLOCK_OPT_RTCFILE 0x20 | 91 | #define HWCLOCK_OPT_RTCFILE 0x20 |
| 92 | 92 | ||
| 93 | int hwclock_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 93 | int hwclock_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 94 | int hwclock_main(int argc, char **argv) | 94 | int hwclock_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 95 | { | 95 | { |
| 96 | unsigned opt; | 96 | unsigned opt; |
| 97 | int utc; | 97 | int utc; |
diff --git a/util-linux/ipcs.c b/util-linux/ipcs.c index 97b98f300..4b5c597e5 100644 --- a/util-linux/ipcs.c +++ b/util-linux/ipcs.c | |||
| @@ -559,7 +559,7 @@ static void print_sem(int semid) | |||
| 559 | } | 559 | } |
| 560 | 560 | ||
| 561 | int ipcs_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 561 | int ipcs_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 562 | int ipcs_main(int argc, char **argv) | 562 | int ipcs_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 563 | { | 563 | { |
| 564 | int id = 0; | 564 | int id = 0; |
| 565 | unsigned flags = 0; | 565 | unsigned flags = 0; |
diff --git a/util-linux/mdev.c b/util-linux/mdev.c index 9c33feb35..0edaf1047 100644 --- a/util-linux/mdev.c +++ b/util-linux/mdev.c | |||
| @@ -244,8 +244,10 @@ static void make_device(char *path, int delete) | |||
| 244 | } | 244 | } |
| 245 | 245 | ||
| 246 | /* File callback for /sys/ traversal */ | 246 | /* File callback for /sys/ traversal */ |
| 247 | static int fileAction(const char *fileName, struct stat *statbuf, | 247 | static int fileAction(const char *fileName, |
| 248 | void *userData, int depth) | 248 | struct stat *statbuf ATTRIBUTE_UNUSED, |
| 249 | void *userData, | ||
| 250 | int depth ATTRIBUTE_UNUSED) | ||
| 249 | { | 251 | { |
| 250 | size_t len = strlen(fileName) - 4; | 252 | size_t len = strlen(fileName) - 4; |
| 251 | char *scratch = userData; | 253 | char *scratch = userData; |
| @@ -261,8 +263,10 @@ static int fileAction(const char *fileName, struct stat *statbuf, | |||
| 261 | } | 263 | } |
| 262 | 264 | ||
| 263 | /* Directory callback for /sys/ traversal */ | 265 | /* Directory callback for /sys/ traversal */ |
| 264 | static int dirAction(const char *fileName, struct stat *statbuf, | 266 | static int dirAction(const char *fileName ATTRIBUTE_UNUSED, |
| 265 | void *userData, int depth) | 267 | struct stat *statbuf ATTRIBUTE_UNUSED, |
| 268 | void *userData ATTRIBUTE_UNUSED, | ||
| 269 | int depth) | ||
| 266 | { | 270 | { |
| 267 | return (depth >= MAX_SYSFS_DEPTH ? SKIP : TRUE); | 271 | return (depth >= MAX_SYSFS_DEPTH ? SKIP : TRUE); |
| 268 | } | 272 | } |
diff --git a/util-linux/mkfs_minix.c b/util-linux/mkfs_minix.c index a784b72f4..3fbdc2020 100644 --- a/util-linux/mkfs_minix.c +++ b/util-linux/mkfs_minix.c | |||
| @@ -495,7 +495,7 @@ static size_t do_check(char *buffer, size_t try, unsigned current_block) | |||
| 495 | return try; | 495 | return try; |
| 496 | } | 496 | } |
| 497 | 497 | ||
| 498 | static void alarm_intr(int alnum) | 498 | static void alarm_intr(int alnum ATTRIBUTE_UNUSED) |
| 499 | { | 499 | { |
| 500 | if (G.currently_testing >= SB_ZONES) | 500 | if (G.currently_testing >= SB_ZONES) |
| 501 | return; | 501 | return; |
| @@ -621,7 +621,7 @@ static void setup_tables(void) | |||
| 621 | } | 621 | } |
| 622 | 622 | ||
| 623 | int mkfs_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 623 | int mkfs_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 624 | int mkfs_minix_main(int argc, char **argv) | 624 | int mkfs_minix_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 625 | { | 625 | { |
| 626 | struct mntent *mp; | 626 | struct mntent *mp; |
| 627 | unsigned opt; | 627 | unsigned opt; |
diff --git a/util-linux/more.c b/util-linux/more.c index 2d5535991..257f40168 100644 --- a/util-linux/more.c +++ b/util-linux/more.c | |||
| @@ -36,7 +36,7 @@ struct globals { | |||
| 36 | #define setTermSettings(fd, argp) tcsetattr(fd, TCSANOW, argp) | 36 | #define setTermSettings(fd, argp) tcsetattr(fd, TCSANOW, argp) |
| 37 | #define getTermSettings(fd, argp) tcgetattr(fd, argp) | 37 | #define getTermSettings(fd, argp) tcgetattr(fd, argp) |
| 38 | 38 | ||
| 39 | static void gotsig(int sig) | 39 | static void gotsig(int sig ATTRIBUTE_UNUSED) |
| 40 | { | 40 | { |
| 41 | bb_putchar('\n'); | 41 | bb_putchar('\n'); |
| 42 | setTermSettings(cin_fileno, &initial_settings); | 42 | setTermSettings(cin_fileno, &initial_settings); |
| @@ -51,7 +51,7 @@ static void gotsig(int sig) | |||
| 51 | #define CONVERTED_TAB_SIZE 8 | 51 | #define CONVERTED_TAB_SIZE 8 |
| 52 | 52 | ||
| 53 | int more_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 53 | int more_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 54 | int more_main(int argc, char **argv) | 54 | int more_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 55 | { | 55 | { |
| 56 | int c = c; /* for gcc */ | 56 | int c = c; /* for gcc */ |
| 57 | int lines; | 57 | int lines; |
diff --git a/util-linux/mount.c b/util-linux/mount.c index 796e1e103..6e63a01fc 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c | |||
| @@ -909,7 +909,7 @@ static inline int daemonize(void) { return -ENOSYS; } | |||
| 909 | #endif | 909 | #endif |
| 910 | 910 | ||
| 911 | // TODO | 911 | // TODO |
| 912 | static inline int we_saw_this_host_before(const char *hostname) | 912 | static inline int we_saw_this_host_before(const char *hostname ATTRIBUTE_UNUSED) |
| 913 | { | 913 | { |
| 914 | return 0; | 914 | return 0; |
| 915 | } | 915 | } |
diff --git a/util-linux/rdate.c b/util-linux/rdate.c index 150efbec4..9e7bdba35 100644 --- a/util-linux/rdate.c +++ b/util-linux/rdate.c | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | 12 | ||
| 13 | enum { RFC_868_BIAS = 2208988800UL }; | 13 | enum { RFC_868_BIAS = 2208988800UL }; |
| 14 | 14 | ||
| 15 | static void socket_timeout(int sig) | 15 | static void socket_timeout(int sig ATTRIBUTE_UNUSED) |
| 16 | { | 16 | { |
| 17 | bb_error_msg_and_die("timeout connecting to time server"); | 17 | bb_error_msg_and_die("timeout connecting to time server"); |
| 18 | } | 18 | } |
| @@ -43,7 +43,7 @@ static time_t askremotedate(const char *host) | |||
| 43 | } | 43 | } |
| 44 | 44 | ||
| 45 | int rdate_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 45 | int rdate_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 46 | int rdate_main(int argc, char **argv) | 46 | int rdate_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 47 | { | 47 | { |
| 48 | time_t remote_time; | 48 | time_t remote_time; |
| 49 | unsigned long flags; | 49 | unsigned long flags; |
diff --git a/util-linux/readprofile.c b/util-linux/readprofile.c index c6152558c..ef7865951 100644 --- a/util-linux/readprofile.c +++ b/util-linux/readprofile.c | |||
| @@ -42,7 +42,7 @@ static const char defaultmap[] ALIGN1 = "/boot/System.map"; | |||
| 42 | static const char defaultpro[] ALIGN1 = "/proc/profile"; | 42 | static const char defaultpro[] ALIGN1 = "/proc/profile"; |
| 43 | 43 | ||
| 44 | int readprofile_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 44 | int readprofile_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 45 | int readprofile_main(int argc, char **argv) | 45 | int readprofile_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 46 | { | 46 | { |
| 47 | FILE *map; | 47 | FILE *map; |
| 48 | const char *mapFile, *proFile, *mult = 0; | 48 | const char *mapFile, *proFile, *mult = 0; |
diff --git a/util-linux/rtcwake.c b/util-linux/rtcwake.c index 2b1ab1fca..6df7334fe 100644 --- a/util-linux/rtcwake.c +++ b/util-linux/rtcwake.c | |||
| @@ -107,7 +107,7 @@ static void suspend_system(const char *suspend) | |||
| 107 | #define RTCWAKE_OPT_TIME 0x40 | 107 | #define RTCWAKE_OPT_TIME 0x40 |
| 108 | 108 | ||
| 109 | int rtcwake_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 109 | int rtcwake_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 110 | int rtcwake_main(int argc, char **argv) | 110 | int rtcwake_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 111 | { | 111 | { |
| 112 | unsigned opt; | 112 | unsigned opt; |
| 113 | const char *rtcname = NULL; | 113 | const char *rtcname = NULL; |
diff --git a/util-linux/script.c b/util-linux/script.c index a4aaa422f..c37fd9d61 100644 --- a/util-linux/script.c +++ b/util-linux/script.c | |||
| @@ -15,13 +15,13 @@ | |||
| 15 | 15 | ||
| 16 | static smallint fd_count = 2; | 16 | static smallint fd_count = 2; |
| 17 | 17 | ||
| 18 | static void handle_sigchld(int sig) | 18 | static void handle_sigchld(int sig ATTRIBUTE_UNUSED) |
| 19 | { | 19 | { |
| 20 | fd_count = 0; | 20 | fd_count = 0; |
| 21 | } | 21 | } |
| 22 | 22 | ||
| 23 | int script_main(int argc, char *argv[]) MAIN_EXTERNALLY_VISIBLE; | 23 | int script_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 24 | int script_main(int argc, char *argv[]) | 24 | int script_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 25 | { | 25 | { |
| 26 | int opt; | 26 | int opt; |
| 27 | int mode; | 27 | int mode; |
diff --git a/util-linux/switch_root.c b/util-linux/switch_root.c index 3a1741179..c030b99e1 100644 --- a/util-linux/switch_root.c +++ b/util-linux/switch_root.c | |||
| @@ -65,7 +65,7 @@ static void delete_contents(const char *directory) | |||
| 65 | } | 65 | } |
| 66 | 66 | ||
| 67 | int switch_root_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 67 | int switch_root_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 68 | int switch_root_main(int argc, char **argv) | 68 | int switch_root_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 69 | { | 69 | { |
| 70 | char *newroot, *console = NULL; | 70 | char *newroot, *console = NULL; |
| 71 | struct stat st1, st2; | 71 | struct stat st1, st2; |
diff --git a/util-linux/umount.c b/util-linux/umount.c index 3f7c0abbd..6136fa97c 100644 --- a/util-linux/umount.c +++ b/util-linux/umount.c | |||
| @@ -27,7 +27,7 @@ | |||
| 27 | //#define MNT_DETACH 0x00000002 /* Just detach from the tree */ | 27 | //#define MNT_DETACH 0x00000002 /* Just detach from the tree */ |
| 28 | 28 | ||
| 29 | int umount_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 29 | int umount_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
| 30 | int umount_main(int argc, char **argv) | 30 | int umount_main(int argc ATTRIBUTE_UNUSED, char **argv) |
| 31 | { | 31 | { |
| 32 | int doForce; | 32 | int doForce; |
| 33 | char *const path = xmalloc(PATH_MAX + 2); /* to save stack */ | 33 | char *const path = xmalloc(PATH_MAX + 2); /* to save stack */ |
