diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-03-29 10:30:50 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-03-29 10:30:50 +0000 |
commit | 3e816c1252cc55e3763f946622129d31ea1f0f20 (patch) | |
tree | 5031fd816b1df09eaa897530a37ce814bba95011 /findutils/find.c | |
parent | 3d43edb28c80ee9cb54335f593d42d5d0471e15a (diff) | |
download | busybox-w32-3e816c1252cc55e3763f946622129d31ea1f0f20.tar.gz busybox-w32-3e816c1252cc55e3763f946622129d31ea1f0f20.tar.bz2 busybox-w32-3e816c1252cc55e3763f946622129d31ea1f0f20.zip |
- fold recurse, depthFirst and dereference params into one param flags.
Minor size improvement (-16b for size, -24b according to bloat-o-meter).
Diffstat (limited to 'findutils/find.c')
-rw-r--r-- | findutils/find.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/findutils/find.c b/findutils/find.c index e98d995a4..c043fbc7d 100644 --- a/findutils/find.c +++ b/findutils/find.c | |||
@@ -574,7 +574,7 @@ static action*** parse_params(char **argv) | |||
574 | int find_main(int argc, char **argv); | 574 | int find_main(int argc, char **argv); |
575 | int find_main(int argc, char **argv) | 575 | int find_main(int argc, char **argv) |
576 | { | 576 | { |
577 | int dereference = FALSE; | 577 | bool dereference = FALSE; |
578 | char *arg; | 578 | char *arg; |
579 | char **argp; | 579 | char **argp; |
580 | int i, firstopt, status = EXIT_SUCCESS; | 580 | int i, firstopt, status = EXIT_SUCCESS; |
@@ -632,13 +632,11 @@ int find_main(int argc, char **argv) | |||
632 | 632 | ||
633 | for (i = 1; i < firstopt; i++) { | 633 | for (i = 1; i < firstopt; i++) { |
634 | if (!recursive_action(argv[i], | 634 | if (!recursive_action(argv[i], |
635 | TRUE, // recurse | 635 | action_recurse|(1<<dereference), /* flags */ |
636 | dereference, // follow links | 636 | fileAction, /* file action */ |
637 | FALSE, // depth first | 637 | fileAction, /* dir action */ |
638 | fileAction, // file action | 638 | NULL, /* user data */ |
639 | fileAction, // dir action | 639 | 0)) /* depth */ |
640 | NULL, // user data | ||
641 | 0)) // depth | ||
642 | status = EXIT_FAILURE; | 640 | status = EXIT_FAILURE; |
643 | } | 641 | } |
644 | return status; | 642 | return status; |