diff options
author | Denis Vlasenko | 2008-03-17 09:00:54 +0000 |
---|---|---|
committer | Denis Vlasenko | 2008-03-17 09:00:54 +0000 |
commit | 68404f13d4bf4826e3609703dad5375763db28ab (patch) | |
tree | b89ed41daeb3a761ac9416a6eed090023b23e7e2 /util-linux | |
parent | a55bd05f3cea6c7cbfb45d15009cb70570c2a43b (diff) | |
download | busybox-68404f13d4bf4826e3609703dad5375763db28ab.zip busybox-68404f13d4bf4826e3609703dad5375763db28ab.tar.gz |
*: 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 cdd385e..9e834ff 100644 --- a/util-linux/dmesg.c +++ b/util-linux/dmesg.c @@ -13,7 +13,7 @@ #include "libbb.h" int dmesg_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int dmesg_main(int argc, char **argv) +int dmesg_main(int argc ATTRIBUTE_UNUSED, char **argv) { int len; char *buf; diff --git a/util-linux/fsck_minix.c b/util-linux/fsck_minix.c index 63f915a..058e8be 100644 --- a/util-linux/fsck_minix.c +++ b/util-linux/fsck_minix.c @@ -1204,7 +1204,7 @@ void check2(void); #endif int fsck_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int fsck_minix_main(int argc, char **argv) +int fsck_minix_main(int argc ATTRIBUTE_UNUSED, char **argv) { struct termios tmp; int retcode = 0; diff --git a/util-linux/hwclock.c b/util-linux/hwclock.c index f226535..44522df 100644 --- a/util-linux/hwclock.c +++ b/util-linux/hwclock.c @@ -91,7 +91,7 @@ static void from_sys_clock(int utc) #define HWCLOCK_OPT_RTCFILE 0x20 int hwclock_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int hwclock_main(int argc, char **argv) +int hwclock_main(int argc ATTRIBUTE_UNUSED, char **argv) { unsigned opt; int utc; diff --git a/util-linux/ipcs.c b/util-linux/ipcs.c index 97b98f3..4b5c597 100644 --- a/util-linux/ipcs.c +++ b/util-linux/ipcs.c @@ -559,7 +559,7 @@ static void print_sem(int semid) } int ipcs_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int ipcs_main(int argc, char **argv) +int ipcs_main(int argc ATTRIBUTE_UNUSED, char **argv) { int id = 0; unsigned flags = 0; diff --git a/util-linux/mdev.c b/util-linux/mdev.c index 9c33feb..0edaf10 100644 --- a/util-linux/mdev.c +++ b/util-linux/mdev.c @@ -244,8 +244,10 @@ static void make_device(char *path, int delete) } /* File callback for /sys/ traversal */ -static int fileAction(const char *fileName, struct stat *statbuf, - void *userData, int depth) +static int fileAction(const char *fileName, + struct stat *statbuf ATTRIBUTE_UNUSED, + void *userData, + int depth ATTRIBUTE_UNUSED) { size_t len = strlen(fileName) - 4; char *scratch = userData; @@ -261,8 +263,10 @@ static int fileAction(const char *fileName, struct stat *statbuf, } /* Directory callback for /sys/ traversal */ -static int dirAction(const char *fileName, struct stat *statbuf, - void *userData, int depth) +static int dirAction(const char *fileName ATTRIBUTE_UNUSED, + struct stat *statbuf ATTRIBUTE_UNUSED, + void *userData ATTRIBUTE_UNUSED, + int depth) { return (depth >= MAX_SYSFS_DEPTH ? SKIP : TRUE); } diff --git a/util-linux/mkfs_minix.c b/util-linux/mkfs_minix.c index a784b72..3fbdc20 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) return try; } -static void alarm_intr(int alnum) +static void alarm_intr(int alnum ATTRIBUTE_UNUSED) { if (G.currently_testing >= SB_ZONES) return; @@ -621,7 +621,7 @@ static void setup_tables(void) } int mkfs_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int mkfs_minix_main(int argc, char **argv) +int mkfs_minix_main(int argc ATTRIBUTE_UNUSED, char **argv) { struct mntent *mp; unsigned opt; diff --git a/util-linux/more.c b/util-linux/more.c index 2d55359..257f401 100644 --- a/util-linux/more.c +++ b/util-linux/more.c @@ -36,7 +36,7 @@ struct globals { #define setTermSettings(fd, argp) tcsetattr(fd, TCSANOW, argp) #define getTermSettings(fd, argp) tcgetattr(fd, argp) -static void gotsig(int sig) +static void gotsig(int sig ATTRIBUTE_UNUSED) { bb_putchar('\n'); setTermSettings(cin_fileno, &initial_settings); @@ -51,7 +51,7 @@ static void gotsig(int sig) #define CONVERTED_TAB_SIZE 8 int more_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int more_main(int argc, char **argv) +int more_main(int argc ATTRIBUTE_UNUSED, char **argv) { int c = c; /* for gcc */ int lines; diff --git a/util-linux/mount.c b/util-linux/mount.c index 796e1e1..6e63a01 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c @@ -909,7 +909,7 @@ static inline int daemonize(void) { return -ENOSYS; } #endif // TODO -static inline int we_saw_this_host_before(const char *hostname) +static inline int we_saw_this_host_before(const char *hostname ATTRIBUTE_UNUSED) { return 0; } diff --git a/util-linux/rdate.c b/util-linux/rdate.c index 150efbe..9e7bdba 100644 --- a/util-linux/rdate.c +++ b/util-linux/rdate.c @@ -12,7 +12,7 @@ enum { RFC_868_BIAS = 2208988800UL }; -static void socket_timeout(int sig) +static void socket_timeout(int sig ATTRIBUTE_UNUSED) { bb_error_msg_and_die("timeout connecting to time server"); } @@ -43,7 +43,7 @@ static time_t askremotedate(const char *host) } int rdate_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int rdate_main(int argc, char **argv) +int rdate_main(int argc ATTRIBUTE_UNUSED, char **argv) { time_t remote_time; unsigned long flags; diff --git a/util-linux/readprofile.c b/util-linux/readprofile.c index c615255..ef78659 100644 --- a/util-linux/readprofile.c +++ b/util-linux/readprofile.c @@ -42,7 +42,7 @@ static const char defaultmap[] ALIGN1 = "/boot/System.map"; static const char defaultpro[] ALIGN1 = "/proc/profile"; int readprofile_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int readprofile_main(int argc, char **argv) +int readprofile_main(int argc ATTRIBUTE_UNUSED, char **argv) { FILE *map; const char *mapFile, *proFile, *mult = 0; diff --git a/util-linux/rtcwake.c b/util-linux/rtcwake.c index 2b1ab1f..6df7334 100644 --- a/util-linux/rtcwake.c +++ b/util-linux/rtcwake.c @@ -107,7 +107,7 @@ static void suspend_system(const char *suspend) #define RTCWAKE_OPT_TIME 0x40 int rtcwake_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int rtcwake_main(int argc, char **argv) +int rtcwake_main(int argc ATTRIBUTE_UNUSED, char **argv) { unsigned opt; const char *rtcname = NULL; diff --git a/util-linux/script.c b/util-linux/script.c index a4aaa42..c37fd9d 100644 --- a/util-linux/script.c +++ b/util-linux/script.c @@ -15,13 +15,13 @@ static smallint fd_count = 2; -static void handle_sigchld(int sig) +static void handle_sigchld(int sig ATTRIBUTE_UNUSED) { fd_count = 0; } -int script_main(int argc, char *argv[]) MAIN_EXTERNALLY_VISIBLE; -int script_main(int argc, char *argv[]) +int script_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; +int script_main(int argc ATTRIBUTE_UNUSED, char **argv) { int opt; int mode; diff --git a/util-linux/switch_root.c b/util-linux/switch_root.c index 3a17411..c030b99 100644 --- a/util-linux/switch_root.c +++ b/util-linux/switch_root.c @@ -65,7 +65,7 @@ static void delete_contents(const char *directory) } int switch_root_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int switch_root_main(int argc, char **argv) +int switch_root_main(int argc ATTRIBUTE_UNUSED, char **argv) { char *newroot, *console = NULL; struct stat st1, st2; diff --git a/util-linux/umount.c b/util-linux/umount.c index 3f7c0ab..6136fa9 100644 --- a/util-linux/umount.c +++ b/util-linux/umount.c @@ -27,7 +27,7 @@ //#define MNT_DETACH 0x00000002 /* Just detach from the tree */ int umount_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; -int umount_main(int argc, char **argv) +int umount_main(int argc ATTRIBUTE_UNUSED, char **argv) { int doForce; char *const path = xmalloc(PATH_MAX + 2); /* to save stack */ |