diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2007-09-27 10:20:47 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2007-09-27 10:20:47 +0000 |
commit | 4daad9004d8f07991516970a1cbd77756fae7041 (patch) | |
tree | f1a17e4b168ef8fdf8af92ac5ce8deba89d38db2 /networking | |
parent | 1acdc89e992eb3f0548ff48ba586b31c9a0ae232 (diff) |
introduce bb_putchar(). saves ~1800 on uclibc (less on glibc).
Diffstat (limited to 'networking')
-rw-r--r-- | networking/ether-wake.c | 2 | ||||
-rw-r--r-- | networking/hostname.c | 2 | ||||
-rw-r--r-- | networking/ifupdown.c | 2 | ||||
-rw-r--r-- | networking/interface.c | 8 | ||||
-rw-r--r-- | networking/libiproute/iptunnel.c | 4 | ||||
-rw-r--r-- | networking/nslookup.c | 2 | ||||
-rw-r--r-- | networking/traceroute.c | 2 | ||||
-rw-r--r-- | networking/wget.c | 2 |
8 files changed, 12 insertions, 12 deletions
diff --git a/networking/ether-wake.c b/networking/ether-wake.c index 36713837a..fc26ad07d 100644 --- a/networking/ether-wake.c +++ b/networking/ether-wake.c @@ -92,7 +92,7 @@ void bb_debug_dump_packet(unsigned char *outpack, int pktsize) printf("packet dump:\n"); for (i = 0; i < pktsize; ++i) { printf("%2.2x ", outpack[i]); - if (i % 20 == 19) puts(""); + if (i % 20 == 19) bb_putchar('\n'); } printf("\n\n"); } diff --git a/networking/hostname.c b/networking/hostname.c index 95dc4515d..6783dbacb 100644 --- a/networking/hostname.c +++ b/networking/hostname.c @@ -83,7 +83,7 @@ int hostname_main(int argc, char **argv) while (hp->h_addr_list[0]) { printf("%s ", inet_ntoa(*(struct in_addr *) (*hp->h_addr_list++))); } - puts(""); + bb_putchar('\n'); } } /* Set the hostname */ diff --git a/networking/ifupdown.c b/networking/ifupdown.c index 299d36346..02e13ed27 100644 --- a/networking/ifupdown.c +++ b/networking/ifupdown.c @@ -1259,7 +1259,7 @@ int ifupdown_main(int argc, char **argv) iface_list = iface_list->link; } if (VERBOSE) { - puts(""); + bb_putchar('\n'); } if (!okay && !FORCE) { diff --git a/networking/interface.c b/networking/interface.c index 61ce12ef1..471ac529e 100644 --- a/networking/interface.c +++ b/networking/interface.c @@ -937,7 +937,7 @@ static void ife_print(struct interface *ptr) printf("(auto)"); } #endif - puts(""); + bb_putchar('\n'); if (ptr->has_ip) { printf(" %s addr:%s ", ap->name, @@ -1073,7 +1073,7 @@ static void ife_print(struct interface *ptr) if (ptr->outfill || ptr->keepalive) printf(" Outfill:%d Keepalive:%d", ptr->outfill, ptr->keepalive); #endif - puts(""); + bb_putchar('\n'); /* If needed, display the interface statistics. */ @@ -1122,9 +1122,9 @@ static void ife_print(struct interface *ptr) } if (ptr->map.dma) printf("DMA chan:%x ", ptr->map.dma); - puts(""); + bb_putchar('\n'); } - puts(""); + bb_putchar('\n'); } diff --git a/networking/libiproute/iptunnel.c b/networking/libiproute/iptunnel.c index 2b1713556..a936a4275 100644 --- a/networking/libiproute/iptunnel.c +++ b/networking/libiproute/iptunnel.c @@ -482,7 +482,7 @@ static void do_tunnels_list(struct ip_tunnel_parm *p) (p->i_key && p1.i_key != p->i_key)) continue; print_tunnel(&p1); - puts(""); + bb_putchar('\n'); } } @@ -512,7 +512,7 @@ static int do_show(int argc, char **argv) return -1; print_tunnel(&p); - puts(""); + bb_putchar('\n'); return 0; } diff --git a/networking/nslookup.c b/networking/nslookup.c index 0036d0d17..e5bb56f81 100644 --- a/networking/nslookup.c +++ b/networking/nslookup.c @@ -112,7 +112,7 @@ static void server_print(void) print_host(server, "Server:"); if (ENABLE_FEATURE_CLEAN_UP) free(server); - puts(""); + bb_putchar('\n'); } /* alter the global _res nameserver structure to use diff --git a/networking/traceroute.c b/networking/traceroute.c index 2d09c7197..e8d486f4c 100644 --- a/networking/traceroute.c +++ b/networking/traceroute.c @@ -1322,7 +1322,7 @@ int traceroute_main(int argc, char **argv) printf(" *"); (void)fflush(stdout); } - putchar('\n'); + bb_putchar('\n'); if (got_there || (unreachable > 0 && unreachable >= nprobes - 1)) break; diff --git a/networking/wget.c b/networking/wget.c index 86d6f00ec..df1a45b2a 100644 --- a/networking/wget.c +++ b/networking/wget.c @@ -142,7 +142,7 @@ static void progressmeter(int flag) /* last call to progressmeter */ alarm(0); transferred = 0; - putc('\n', stderr); + fputc('\n', stderr); } else { if (flag == -1) { /* first call to progressmeter */ |