dumpleases: string reuse
authorDenys Vlasenko <vda.linux@googlemail.com>
Sat, 24 Oct 2015 18:45:10 +0000 (20:45 +0200)
committerDenys Vlasenko <vda.linux@googlemail.com>
Sat, 24 Oct 2015 18:45:10 +0000 (20:45 +0200)
   text    data     bss     dec     hex filename
 926254     906   17160  944320   e68c0 busybox_old
 926242     906   17160  944308   e68b4 busybox_unstripped

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
networking/udhcp/dumpleases.c

index f68e499e7345950a53a84ade4da0c797ef073787..987cc9aff42694853c35dcce96f31b80243b03f0 100644 (file)
@@ -57,10 +57,12 @@ int dumpleases_main(int argc UNUSED_PARAM, char **argv)
 
        fd = xopen(file, O_RDONLY);
 
-       printf("Mac Address       IP Address      Host Name           Expires %s\n",
-               (opt & OPT_a) ? "at" : "in");
-       /*     "00:00:00:00:00:00 255.255.255.255 ABCDEFGHIJKLMNOPQRS Wed Jun 30 21:49:08 1993" */
        /*     "123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 */
+       /*     "00:00:00:00:00:00 255.255.255.255 ABCDEFGHIJKLMNOPQRS Wed Jun 30 21:49:08 1993" */
+       printf("Mac %-14s"       "IP %-13s"      "Host %-15s"        "Expires %s\n",
+               "Address", "Address", "Name",
+               (opt & OPT_a) ? "at" : "in"
+       );
 
        xread(fd, &written_at, sizeof(written_at));
        written_at = SWAP_BE64(written_at);