diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2015-10-07 22:42:45 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2015-10-07 22:42:45 +0200 |
commit | d60752f8c9be5689a249ad518deb38061d4bc45e (patch) | |
tree | 06df5c7e22be59561cbbcd22eb63ff95344fe321 /util-linux/fsck_minix.c | |
parent | 8c0708a329618b20089eb9cedbe06522dd25d9be (diff) | |
download | busybox-w32-d60752f8c9be5689a249ad518deb38061d4bc45e.tar.gz busybox-w32-d60752f8c9be5689a249ad518deb38061d4bc45e.tar.bz2 busybox-w32-d60752f8c9be5689a249ad518deb38061d4bc45e.zip |
build system: -fno-builtin-printf
Benefits are: drops reference to out-of-line putchar(), fixes a few cases
of failed string merge.
function old new delta
i2cdump_main 1488 1502 +14
sha256_process_block64 423 433 +10
sendmail_main 1183 1185 +2
list_table 1114 1116 +2
i2cdetect_main 1235 1237 +2
fdisk_main 2852 2854 +2
builtin_type 119 121 +2
unicode_conv_to_printable2 325 324 -1
scan_recursive 380 378 -2
mkfs_minix_main 2687 2684 -3
buffer_fill_and_print 178 169 -9
putchar 152 - -152
------------------------------------------------------------------------------
(add/remove: 0/2 grow/shrink: 7/4 up/down: 34/-167) Total: -133 bytes
text data bss dec hex filename
937788 932 17676 956396 e97ec busybox_old
937564 932 17676 956172 e970c busybox_unstripped
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux/fsck_minix.c')
-rw-r--r-- | util-linux/fsck_minix.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/util-linux/fsck_minix.c b/util-linux/fsck_minix.c index 33767a1af..d2f3524b4 100644 --- a/util-linux/fsck_minix.c +++ b/util-linux/fsck_minix.c | |||
@@ -371,9 +371,9 @@ static int ask(const char *string, int def) | |||
371 | } | 371 | } |
372 | } | 372 | } |
373 | if (def) | 373 | if (def) |
374 | printf("y\n"); | 374 | puts("y"); |
375 | else { | 375 | else { |
376 | printf("n\n"); | 376 | puts("n"); |
377 | errors_uncorrected = 1; | 377 | errors_uncorrected = 1; |
378 | } | 378 | } |
379 | return def; | 379 | return def; |
@@ -405,7 +405,7 @@ static void check_mount(void) | |||
405 | if (isatty(0) && isatty(1)) | 405 | if (isatty(0) && isatty(1)) |
406 | cont = ask("Do you really want to continue", 0); | 406 | cont = ask("Do you really want to continue", 0); |
407 | if (!cont) { | 407 | if (!cont) { |
408 | printf("Check aborted\n"); | 408 | puts("Check aborted"); |
409 | exit(EXIT_SUCCESS); | 409 | exit(EXIT_SUCCESS); |
410 | } | 410 | } |
411 | } | 411 | } |
@@ -470,8 +470,8 @@ static void write_block(unsigned nr, void *addr) | |||
470 | if (!nr) | 470 | if (!nr) |
471 | return; | 471 | return; |
472 | if (nr < FIRSTZONE || nr >= ZONES) { | 472 | if (nr < FIRSTZONE || nr >= ZONES) { |
473 | printf("Internal error: trying to write bad block\n" | 473 | puts("Internal error: trying to write bad block\n" |
474 | "Write request ignored\n"); | 474 | "Write request ignored"); |
475 | errors_uncorrected = 1; | 475 | errors_uncorrected = 1; |
476 | return; | 476 | return; |
477 | } | 477 | } |
@@ -659,7 +659,7 @@ static void read_tables(void) | |||
659 | if (INODE_BUFFER_SIZE != read(dev_fd, inode_buffer, INODE_BUFFER_SIZE)) | 659 | if (INODE_BUFFER_SIZE != read(dev_fd, inode_buffer, INODE_BUFFER_SIZE)) |
660 | die("can't read inodes"); | 660 | die("can't read inodes"); |
661 | if (NORM_FIRSTZONE != FIRSTZONE) { | 661 | if (NORM_FIRSTZONE != FIRSTZONE) { |
662 | printf("warning: firstzone!=norm_firstzone\n"); | 662 | puts("warning: firstzone!=norm_firstzone"); |
663 | errors_uncorrected = 1; | 663 | errors_uncorrected = 1; |
664 | } | 664 | } |
665 | get_dirsize(); | 665 | get_dirsize(); |
@@ -713,7 +713,7 @@ static void get_inode_common(unsigned nr, uint16_t i_mode) | |||
713 | } else | 713 | } else |
714 | links++; | 714 | links++; |
715 | if (!++inode_count[nr]) { | 715 | if (!++inode_count[nr]) { |
716 | printf("Warning: inode count too big\n"); | 716 | puts("Warning: inode count too big"); |
717 | inode_count[nr]--; | 717 | inode_count[nr]--; |
718 | errors_uncorrected = 1; | 718 | errors_uncorrected = 1; |
719 | } | 719 | } |
@@ -1299,7 +1299,7 @@ int fsck_minix_main(int argc UNUSED_PARAM, char **argv) | |||
1299 | } | 1299 | } |
1300 | if (changed) { | 1300 | if (changed) { |
1301 | write_tables(); | 1301 | write_tables(); |
1302 | printf("FILE SYSTEM HAS BEEN CHANGED\n"); | 1302 | puts("FILE SYSTEM HAS BEEN CHANGED"); |
1303 | sync(); | 1303 | sync(); |
1304 | } else if (OPT_repair) | 1304 | } else if (OPT_repair) |
1305 | write_superblock(); | 1305 | write_superblock(); |