diff options
author | Matt Kraai <kraai@debian.org> | 2000-12-05 05:11:41 +0000 |
---|---|---|
committer | Matt Kraai <kraai@debian.org> | 2000-12-05 05:11:41 +0000 |
commit | d27753afd983ffeae45b80dee92f02d0518ca7bf (patch) | |
tree | 1ecefa6dc73279cfe4ae3a45cc647823094248f0 /utility.c | |
parent | 0e836ed8db86ef0274510c27e173f7ac66c6b2a6 (diff) | |
download | busybox-w32-d27753afd983ffeae45b80dee92f02d0518ca7bf.tar.gz busybox-w32-d27753afd983ffeae45b80dee92f02d0518ca7bf.tar.bz2 busybox-w32-d27753afd983ffeae45b80dee92f02d0518ca7bf.zip |
Use perrorMsg instead of perror and keep removing files if we encounter
an error.
Diffstat (limited to 'utility.c')
-rw-r--r-- | utility.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -641,7 +641,7 @@ int recursiveAction(const char *fileName, | |||
641 | "status=%d followLinks=%d TRUE=%d\n", | 641 | "status=%d followLinks=%d TRUE=%d\n", |
642 | status, followLinks, TRUE); | 642 | status, followLinks, TRUE); |
643 | #endif | 643 | #endif |
644 | perror(fileName); | 644 | perrorMsg("%s", fileName); |
645 | return FALSE; | 645 | return FALSE; |
646 | } | 646 | } |
647 | 647 | ||
@@ -666,13 +666,13 @@ int recursiveAction(const char *fileName, | |||
666 | 666 | ||
667 | dir = opendir(fileName); | 667 | dir = opendir(fileName); |
668 | if (!dir) { | 668 | if (!dir) { |
669 | perror(fileName); | 669 | perrorMsg("%s", fileName); |
670 | return FALSE; | 670 | return FALSE; |
671 | } | 671 | } |
672 | if (dirAction != NULL && depthFirst == FALSE) { | 672 | if (dirAction != NULL && depthFirst == FALSE) { |
673 | status = dirAction(fileName, &statbuf, userData); | 673 | status = dirAction(fileName, &statbuf, userData); |
674 | if (status == FALSE) { | 674 | if (status == FALSE) { |
675 | perror(fileName); | 675 | perrorMsg("%s", fileName); |
676 | return FALSE; | 676 | return FALSE; |
677 | } | 677 | } |
678 | } | 678 | } |
@@ -699,13 +699,13 @@ int recursiveAction(const char *fileName, | |||
699 | } | 699 | } |
700 | status = closedir(dir); | 700 | status = closedir(dir); |
701 | if (status < 0) { | 701 | if (status < 0) { |
702 | perror(fileName); | 702 | perrorMsg("%s", fileName); |
703 | return FALSE; | 703 | return FALSE; |
704 | } | 704 | } |
705 | if (dirAction != NULL && depthFirst == TRUE) { | 705 | if (dirAction != NULL && depthFirst == TRUE) { |
706 | status = dirAction(fileName, &statbuf, userData); | 706 | status = dirAction(fileName, &statbuf, userData); |
707 | if (status == FALSE) { | 707 | if (status == FALSE) { |
708 | perror(fileName); | 708 | perrorMsg("%s", fileName); |
709 | return FALSE; | 709 | return FALSE; |
710 | } | 710 | } |
711 | } | 711 | } |