aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2007-03-07 09:35:43 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2007-03-07 09:35:43 +0000
commit8e858e2700651a0e973169b579622cd3dcd0defd (patch)
tree4829004760bedec63aa8a72affe75591e482fe4a
parent41cca2b4f54a2c8dadd2469747aca91d891c0b15 (diff)
downloadbusybox-w32-8e858e2700651a0e973169b579622cd3dcd0defd.tar.gz
busybox-w32-8e858e2700651a0e973169b579622cd3dcd0defd.tar.bz2
busybox-w32-8e858e2700651a0e973169b579622cd3dcd0defd.zip
clean up accumulated whitespace damage
-rw-r--r--coreutils/od_bloaty.c6
-rw-r--r--editors/sed.c2
-rw-r--r--editors/vi.c2
-rw-r--r--include/libbb.h2
-rw-r--r--include/usage.h6
-rw-r--r--libbb/create_icmp_socket.c2
-rw-r--r--libbb/getopt32.c6
-rw-r--r--libbb/read.c2
-rw-r--r--libbb/xfuncs.c2
-rw-r--r--loginutils/adduser.c2
-rw-r--r--miscutils/less.c4
-rw-r--r--networking/httpd.c7
-rw-r--r--networking/ifupdown.c2
-rw-r--r--networking/udhcp/domain_codec.c2
-rw-r--r--selinux/selinuxenabled.c2
-rw-r--r--shell/ash.c2
-rw-r--r--shell/ash_test/printenv.c2
-rw-r--r--shell/msh.c2
-rw-r--r--util-linux/fdisk_sgi.c6
19 files changed, 31 insertions, 30 deletions
diff --git a/coreutils/od_bloaty.c b/coreutils/od_bloaty.c
index c69470a14..74765f842 100644
--- a/coreutils/od_bloaty.c
+++ b/coreutils/od_bloaty.c
@@ -542,7 +542,7 @@ check_and_close(void)
542 fmt = SIGNED_DECIMAL; 542 fmt = SIGNED_DECIMAL;
543 size = INT or LONG; (whichever integral_type_size[4] resolves to) 543 size = INT or LONG; (whichever integral_type_size[4] resolves to)
544 print_function = print_int; (assuming size == INT) 544 print_function = print_int; (assuming size == INT)
545 fmt_string = "%011d%c"; 545 fmt_string = "%011d%c";
546 } 546 }
547 S_ORIG is solely for reporting errors. It should be the full format 547 S_ORIG is solely for reporting errors. It should be the full format
548 string argument. */ 548 string argument. */
@@ -823,7 +823,7 @@ skip(off_t n_skip)
823 n_bytes_read = fread(buf, 1, n_bytes_to_read, in_stream); 823 n_bytes_read = fread(buf, 1, n_bytes_to_read, in_stream);
824 n_skip -= n_bytes_read; 824 n_skip -= n_bytes_read;
825 if (n_bytes_read != n_bytes_to_read) 825 if (n_bytes_read != n_bytes_to_read)
826 break; /* EOF on this file or error */ 826 break; /* EOF on this file or error */
827 } 827 }
828 } 828 }
829 if (n_skip == 0) 829 if (n_skip == 0)
@@ -1334,7 +1334,7 @@ int od_main(int argc, char **argv)
1334 /* If the --traditional option is used, there may be from 1334 /* If the --traditional option is used, there may be from
1335 * 0 to 3 remaining command line arguments; handle each case 1335 * 0 to 3 remaining command line arguments; handle each case
1336 * separately. 1336 * separately.
1337 * od [file] [[+]offset[.][b] [[+]label[.][b]]] 1337 * od [file] [[+]offset[.][b] [[+]label[.][b]]]
1338 * The offset and pseudo_start have the same syntax. 1338 * The offset and pseudo_start have the same syntax.
1339 * 1339 *
1340 * FIXME: POSIX 1003.1-2001 with XSI requires support for the 1340 * FIXME: POSIX 1003.1-2001 with XSI requires support for the
diff --git a/editors/sed.c b/editors/sed.c
index b8f00c0c9..c434eee1b 100644
--- a/editors/sed.c
+++ b/editors/sed.c
@@ -896,7 +896,7 @@ restart:
896 /* or does this line matches our last address regex */ 896 /* or does this line matches our last address regex */
897 || (sed_cmd->end_match && old_matched 897 || (sed_cmd->end_match && old_matched
898 && (regexec(sed_cmd->end_match, 898 && (regexec(sed_cmd->end_match,
899 pattern_space, 0, NULL, 0) == 0)) 899 pattern_space, 0, NULL, 0) == 0))
900 ); 900 );
901 } 901 }
902 902
diff --git a/editors/vi.c b/editors/vi.c
index 45a80517d..6898e61a4 100644
--- a/editors/vi.c
+++ b/editors/vi.c
@@ -84,7 +84,7 @@ enum {
84 S_TO_WS = 2, // used in skip_thing() for moving "dot" 84 S_TO_WS = 2, // used in skip_thing() for moving "dot"
85 S_OVER_WS = 3, // used in skip_thing() for moving "dot" 85 S_OVER_WS = 3, // used in skip_thing() for moving "dot"
86 S_END_PUNCT = 4, // used in skip_thing() for moving "dot" 86 S_END_PUNCT = 4, // used in skip_thing() for moving "dot"
87 S_END_ALNUM = 5 // used in skip_thing() for moving "dot" 87 S_END_ALNUM = 5, // used in skip_thing() for moving "dot"
88}; 88};
89 89
90typedef unsigned char Byte; 90typedef unsigned char Byte;
diff --git a/include/libbb.h b/include/libbb.h
index 809d8446a..9aa060691 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -575,7 +575,7 @@ int bb_execvp(const char *file, char *const argv[]);
575 cmd, __VA_ARGS__) 575 cmd, __VA_ARGS__)
576#else 576#else
577#define BB_EXECVP(prog,cmd) execvp(prog,cmd) 577#define BB_EXECVP(prog,cmd) execvp(prog,cmd)
578#define BB_EXECLP(prog,cmd,...) execlp(prog,cmd, __VA_ARGS__) 578#define BB_EXECLP(prog,cmd,...) execlp(prog,cmd, __VA_ARGS__)
579#endif 579#endif
580 580
581USE_DESKTOP(long long) int uncompress(int fd_in, int fd_out); 581USE_DESKTOP(long long) int uncompress(int fd_in, int fd_out);
diff --git a/include/usage.h b/include/usage.h
index 04dddd7c3..5073c9b8a 100644
--- a/include/usage.h
+++ b/include/usage.h
@@ -60,7 +60,7 @@
60 "[-vn] [-H type] [-i if] -a [hostname]\n" \ 60 "[-vn] [-H type] [-i if] -a [hostname]\n" \
61 "[-v] [-i if] -d hostname [pub]\n" \ 61 "[-v] [-i if] -d hostname [pub]\n" \
62 "[-v] [-H type] [-i if] -s hostname hw_addr [temp]\n" \ 62 "[-v] [-H type] [-i if] -s hostname hw_addr [temp]\n" \
63 "[-v] [-H type] [-i if] -s hostname hw_addr [netmask nm] pub\n" \ 63 "[-v] [-H type] [-i if] -s hostname hw_addr [netmask nm] pub\n" \
64 "[-v] [-H type] [-i if] -Ds hostname ifa [netmask nm] pub\n" 64 "[-v] [-H type] [-i if] -Ds hostname ifa [netmask nm] pub\n"
65#define arp_full_usage \ 65#define arp_full_usage \
66 "Manipulate the system ARP cache" \ 66 "Manipulate the system ARP cache" \
@@ -269,7 +269,7 @@
269 "Change the process state and run specified program" \ 269 "Change the process state and run specified program" \
270 "\n\nOptions:\n" \ 270 "\n\nOptions:\n" \
271 " -u user[:grp] Set uid and gid\n" \ 271 " -u user[:grp] Set uid and gid\n" \
272 " -U user[:grp] Set environment variables UID and GID\n" \ 272 " -U user[:grp] Set environment variables UID and GID\n" \
273 " -e dir Set environment variables as specified by files\n" \ 273 " -e dir Set environment variables as specified by files\n" \
274 " in the directory: file=1st_line_of_file\n" \ 274 " in the directory: file=1st_line_of_file\n" \
275 " -/ dir Chroot to dir\n" \ 275 " -/ dir Chroot to dir\n" \
@@ -1776,7 +1776,7 @@
1776 1776
1777#define ls_trivial_usage \ 1777#define ls_trivial_usage \
1778 "[-1Aa" USE_FEATURE_LS_TIMESTAMPS("c") "Cd" \ 1778 "[-1Aa" USE_FEATURE_LS_TIMESTAMPS("c") "Cd" \
1779 USE_FEATURE_LS_TIMESTAMPS("e") USE_FEATURE_LS_FILETYPES("F") "iln" \ 1779 USE_FEATURE_LS_TIMESTAMPS("e") USE_FEATURE_LS_FILETYPES("F") "iln" \
1780 USE_FEATURE_LS_FILETYPES("p") USE_FEATURE_LS_FOLLOWLINKS("L") \ 1780 USE_FEATURE_LS_FILETYPES("p") USE_FEATURE_LS_FOLLOWLINKS("L") \
1781 USE_FEATURE_LS_RECURSIVE("R") USE_FEATURE_LS_SORTFILES("rS") "s" \ 1781 USE_FEATURE_LS_RECURSIVE("R") USE_FEATURE_LS_SORTFILES("rS") "s" \
1782 USE_FEATURE_AUTOWIDTH("T") USE_FEATURE_LS_TIMESTAMPS("tu") \ 1782 USE_FEATURE_AUTOWIDTH("T") USE_FEATURE_LS_TIMESTAMPS("tu") \
diff --git a/libbb/create_icmp_socket.c b/libbb/create_icmp_socket.c
index 666454888..dbd4769f6 100644
--- a/libbb/create_icmp_socket.c
+++ b/libbb/create_icmp_socket.c
@@ -22,7 +22,7 @@ int create_icmp_socket(void)
22 * proto->p_proto to have the correct value for "icmp" */ 22 * proto->p_proto to have the correct value for "icmp" */
23 sock = socket(AF_INET, SOCK_RAW, 23 sock = socket(AF_INET, SOCK_RAW,
24 (proto ? proto->p_proto : 1)); /* 1 == ICMP */ 24 (proto ? proto->p_proto : 1)); /* 1 == ICMP */
25 if (sock < 0) { 25 if (sock < 0) {
26 if (errno == EPERM) 26 if (errno == EPERM)
27 bb_error_msg_and_die(bb_msg_perm_denied_are_you_root); 27 bb_error_msg_and_die(bb_msg_perm_denied_are_you_root);
28 bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket); 28 bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket);
diff --git a/libbb/getopt32.c b/libbb/getopt32.c
index f93438df0..9f5fd60bd 100644
--- a/libbb/getopt32.c
+++ b/libbb/getopt32.c
@@ -79,9 +79,9 @@ const struct option *applet_long_options
79 (see getopt(3)) 79 (see getopt(3))
80 80
81 static const struct option applet_long_options[] = { 81 static const struct option applet_long_options[] = {
82 //name,has_arg,flag,val 82 //name,has_arg,flag,val
83 { "verbose", 0, 0, 'v' }, 83 { "verbose", 0, 0, 'v' },
84 { 0, 0, 0, 0 } 84 { 0, 0, 0, 0 }
85 }; 85 };
86 applet_long_options = applet_long_options; 86 applet_long_options = applet_long_options;
87 87
diff --git a/libbb/read.c b/libbb/read.c
index 861828da1..c05b26b50 100644
--- a/libbb/read.c
+++ b/libbb/read.c
@@ -129,7 +129,7 @@ void *xmalloc_open_read_close(const char *filename, size_t *sizep)
129 buf = xmalloc(size + 1); 129 buf = xmalloc(size + 1);
130 size = read_close(fd, buf, size); 130 size = read_close(fd, buf, size);
131 if ((ssize_t)size < 0) 131 if ((ssize_t)size < 0)
132 bb_perror_msg_and_die("'%s'", filename); 132 bb_perror_msg_and_die("'%s'", filename);
133 xrealloc(buf, size + 1); 133 xrealloc(buf, size + 1);
134 buf[size] = '\0'; 134 buf[size] = '\0';
135 if (sizep) *sizep = size; 135 if (sizep) *sizep = size;
diff --git a/libbb/xfuncs.c b/libbb/xfuncs.c
index f6444bbc6..2cc6a8299 100644
--- a/libbb/xfuncs.c
+++ b/libbb/xfuncs.c
@@ -522,7 +522,7 @@ void bb_sanitize_stdio_maybe_daemonize(int daemonize)
522 bb_perror_msg_and_die("fork"); 522 bb_perror_msg_and_die("fork");
523 if (pid) /* parent */ 523 if (pid) /* parent */
524 exit(0); 524 exit(0);
525 /* child */ 525 /* child */
526 /* if daemonizing, make sure we detach from stdio */ 526 /* if daemonizing, make sure we detach from stdio */
527 setsid(); 527 setsid();
528 dup2(fd, 0); 528 dup2(fd, 0);
diff --git a/loginutils/adduser.c b/loginutils/adduser.c
index b6d0c62ea..e0cdd1ced 100644
--- a/loginutils/adduser.c
+++ b/loginutils/adduser.c
@@ -101,7 +101,7 @@ static int adduser(struct passwd *p, unsigned long flags)
101 bb_error_msg_and_die("illegal uid or no uids left"); 101 bb_error_msg_and_die("illegal uid or no uids left");
102 case 3: 102 case 3:
103 bb_error_msg_and_die("%s: group name already in use", p->pw_name); 103 bb_error_msg_and_die("%s: group name already in use", p->pw_name);
104 } 104 }
105 105
106 /* add to passwd */ 106 /* add to passwd */
107 if (putpwent(p, file) == -1) { 107 if (putpwent(p, file) == -1) {
diff --git a/miscutils/less.c b/miscutils/less.c
index 1be5d3520..3db7c9cdb 100644
--- a/miscutils/less.c
+++ b/miscutils/less.c
@@ -883,13 +883,13 @@ static void number_process(int first_digit)
883 break; 883 break;
884 case 'g': case '<': case 'G': case '>': 884 case 'g': case '<': case 'G': case '>':
885 cur_fline = num + max_displayed_line; 885 cur_fline = num + max_displayed_line;
886 read_lines(); 886 read_lines();
887 buffer_line(num - 1); 887 buffer_line(num - 1);
888 break; 888 break;
889 case 'p': case '%': 889 case 'p': case '%':
890 num = num * (max_fline / 100); /* + max_fline / 2; */ 890 num = num * (max_fline / 100); /* + max_fline / 2; */
891 cur_fline = num + max_displayed_line; 891 cur_fline = num + max_displayed_line;
892 read_lines(); 892 read_lines();
893 buffer_line(num); 893 buffer_line(num);
894 break; 894 break;
895#if ENABLE_FEATURE_LESS_REGEXP 895#if ENABLE_FEATURE_LESS_REGEXP
diff --git a/networking/httpd.c b/networking/httpd.c
index cb8ab763f..ee408eb14 100644
--- a/networking/httpd.c
+++ b/networking/httpd.c
@@ -873,8 +873,9 @@ static int sendHeaders(HttpResponseNum responseNum)
873 873
874#if ENABLE_FEATURE_HTTPD_BASIC_AUTH 874#if ENABLE_FEATURE_HTTPD_BASIC_AUTH
875 if (responseNum == HTTP_UNAUTHORIZED) { 875 if (responseNum == HTTP_UNAUTHORIZED) {
876 len += sprintf(buf+len, "WWW-Authenticate: Basic realm=\"%s\"\r\n", 876 len += sprintf(buf+len,
877 config->realm); 877 "WWW-Authenticate: Basic realm=\"%s\"\r\n",
878 config->realm);
878 } 879 }
879#endif 880#endif
880 if (responseNum == HTTP_MOVED_TEMPORARILY) { 881 if (responseNum == HTTP_MOVED_TEMPORARILY) {
@@ -2000,7 +2001,7 @@ int httpd_main(int argc, char *argv[])
2000 if (opt & OPT_SETUID) { 2001 if (opt & OPT_SETUID) {
2001 if (ugid.gid != (gid_t)-1) { 2002 if (ugid.gid != (gid_t)-1) {
2002 if (setgroups(1, &ugid.gid) == -1) 2003 if (setgroups(1, &ugid.gid) == -1)
2003 bb_perror_msg_and_die("setgroups"); 2004 bb_perror_msg_and_die("setgroups");
2004 xsetgid(ugid.gid); 2005 xsetgid(ugid.gid);
2005 } 2006 }
2006 xsetuid(ugid.uid); 2007 xsetuid(ugid.uid);
diff --git a/networking/ifupdown.c b/networking/ifupdown.c
index c7cb85350..8e750feaf 100644
--- a/networking/ifupdown.c
+++ b/networking/ifupdown.c
@@ -421,7 +421,7 @@ static int static_up(struct interface_defn_t *ifd, execfn *exec)
421 result += execute("ifconfig %iface% %address% netmask %netmask%" 421 result += execute("ifconfig %iface% %address% netmask %netmask%"
422 "[[ broadcast %broadcast%]][[ pointopoint %pointopoint%]] ", 422 "[[ broadcast %broadcast%]][[ pointopoint %pointopoint%]] ",
423 ifd, exec); 423 ifd, exec);
424 result += execute("[[route add default gw %gateway% %iface%]]", ifd, exec); 424 result += execute("[[route add default gw %gateway% %iface%]]", ifd, exec);
425 return ((result == 3) ? 3 : 0); 425 return ((result == 3) ? 3 : 0);
426#endif 426#endif
427} 427}
diff --git a/networking/udhcp/domain_codec.c b/networking/udhcp/domain_codec.c
index 6e16ddedc..239ae5b5c 100644
--- a/networking/udhcp/domain_codec.c
+++ b/networking/udhcp/domain_codec.c
@@ -200,6 +200,6 @@ uint8_t *dname_enc(const uint8_t *cstr, int clen, const char *src, int *retlen)
200 200
201 *retlen = d - dname + 1; 201 *retlen = d - dname + 1;
202 return dname; 202 return dname;
203} 203}
204 204
205#endif /* ENABLE_FEATURE_RFC3397 */ 205#endif /* ENABLE_FEATURE_RFC3397 */
diff --git a/selinux/selinuxenabled.c b/selinux/selinuxenabled.c
index 400995af0..c93ba706f 100644
--- a/selinux/selinuxenabled.c
+++ b/selinux/selinuxenabled.c
@@ -1,6 +1,6 @@
1/* 1/*
2 * selinuxenabled 2 * selinuxenabled
3 * 3 *
4 * Based on libselinux 1.33.1 4 * Based on libselinux 1.33.1
5 * Port to BusyBox Hiroshi Shinji <shiroshi@my.email.ne.jp> 5 * Port to BusyBox Hiroshi Shinji <shiroshi@my.email.ne.jp>
6 * 6 *
diff --git a/shell/ash.c b/shell/ash.c
index f32c31180..bfa4a8c6d 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -11197,7 +11197,7 @@ find_command(char *name, struct cmdentry *entry, int act, const char *path)
11197 goto builtin_success; 11197 goto builtin_success;
11198 } else if (builtinloc <= 0) { 11198 } else if (builtinloc <= 0) {
11199 goto builtin_success; 11199 goto builtin_success;
11200 } 11200 }
11201 } 11201 }
11202 11202
11203 /* We have to search path. */ 11203 /* We have to search path. */
diff --git a/shell/ash_test/printenv.c b/shell/ash_test/printenv.c
index 07ea2a9f0..06df21fdc 100644
--- a/shell/ash_test/printenv.c
+++ b/shell/ash_test/printenv.c
@@ -30,7 +30,7 @@
30extern char **environ; 30extern char **environ;
31 31
32int 32int
33main (argc, argv) 33main (argc, argv)
34 int argc; 34 int argc;
35 char **argv; 35 char **argv;
36{ 36{
diff --git a/shell/msh.c b/shell/msh.c
index 968f073cd..58c498b61 100644
--- a/shell/msh.c
+++ b/shell/msh.c
@@ -3723,7 +3723,7 @@ static char *evalstr(char *cp, int f)
3723 if (wb == NULL || wb->w_nword == 0 3723 if (wb == NULL || wb->w_nword == 0
3724 || (cp = wb->w_words[0]) == NULL 3724 || (cp = wb->w_words[0]) == NULL
3725 ) { 3725 ) {
3726// TODO: I suspect that 3726// TODO: I suspect that
3727// char *evalstr(char *cp, int f) is actually 3727// char *evalstr(char *cp, int f) is actually
3728// const char *evalstr(const char *cp, int f)! 3728// const char *evalstr(const char *cp, int f)!
3729 cp = (char*)""; 3729 cp = (char*)"";
diff --git a/util-linux/fdisk_sgi.c b/util-linux/fdisk_sgi.c
index bb354d8d9..937ac883b 100644
--- a/util-linux/fdisk_sgi.c
+++ b/util-linux/fdisk_sgi.c
@@ -356,9 +356,9 @@ sgi_set_swappartition(int i)
356static int 356static int
357sgi_check_bootfile(const char* aFile) 357sgi_check_bootfile(const char* aFile)
358{ 358{
359 if (strlen(aFile) < 3) /* "/a\n" is minimum */ { 359 if (strlen(aFile) < 3) /* "/a\n" is minimum */ {
360 printf(_("\nInvalid Bootfile!\n" 360 printf(_("\nInvalid Bootfile!\n"
361 "\tThe bootfile must be an absolute non-zero pathname,\n" 361 "\tThe bootfile must be an absolute non-zero pathname,\n"
362 "\te.g. \"/unix\" or \"/unix.save\".\n")); 362 "\te.g. \"/unix\" or \"/unix.save\".\n"));
363 return 0; 363 return 0;
364 } else { 364 } else {