summaryrefslogtreecommitdiff
path: root/coreutils/touch.c
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer2007-01-20 21:32:38 +0000
committerBernhard Reutner-Fischer2007-01-20 21:32:38 +0000
commitd19f4aaa21b9530f59f51465df18a376c7ba30e6 (patch)
tree4e67cd1046f7a881dfcfdd7b5c64300b00d4c97c /coreutils/touch.c
parent1118a1de46cdeb166f256374568f4bc21b5d7449 (diff)
downloadbusybox-d19f4aaa21b9530f59f51465df18a376c7ba30e6.zip
busybox-d19f4aaa21b9530f59f51465df18a376c7ba30e6.tar.gz
- small size tweak
Diffstat (limited to 'coreutils/touch.c')
-rw-r--r--coreutils/touch.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/coreutils/touch.c b/coreutils/touch.c
index e1af7d0..72bf904 100644
--- a/coreutils/touch.c
+++ b/coreutils/touch.c
@@ -29,10 +29,8 @@
int touch_main(int argc, char **argv)
{
int fd;
- int flags;
int status = EXIT_SUCCESS;
-
- flags = getopt32(argc, argv, "c");
+ bool flags = (getopt32(argc, argv, "c") & 1);
argv += optind;
@@ -43,7 +41,7 @@ int touch_main(int argc, char **argv)
do {
if (utime(*argv, NULL)) {
if (errno == ENOENT) { /* no such file*/
- if (flags & 1) { /* Creation is disabled, so ignore. */
+ if (flags) { /* Creation is disabled, so ignore. */
continue;
}
/* Try to create the file. */