diff options
-rw-r--r-- | util-linux/rdate.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util-linux/rdate.c b/util-linux/rdate.c index 2ca585fec..6e35cd519 100644 --- a/util-linux/rdate.c +++ b/util-linux/rdate.c | |||
@@ -61,7 +61,7 @@ int rdate_main(int argc UNUSED_PARAM, char **argv) | |||
61 | 61 | ||
62 | remote_time = askremotedate(argv[optind]); | 62 | remote_time = askremotedate(argv[optind]); |
63 | 63 | ||
64 | if (!(flags & 2)) { | 64 | if (!(flags & 2)) { /* no -p (-s may be present) */ |
65 | time_t current_time; | 65 | time_t current_time; |
66 | 66 | ||
67 | time(¤t_time); | 67 | time(¤t_time); |
@@ -72,7 +72,7 @@ int rdate_main(int argc UNUSED_PARAM, char **argv) | |||
72 | bb_perror_msg_and_die("can't set time of day"); | 72 | bb_perror_msg_and_die("can't set time of day"); |
73 | } | 73 | } |
74 | 74 | ||
75 | if ((flags & 2) || !(flags & 1)) | 75 | if (flags != 1) /* not lone -s */ |
76 | printf("%s", ctime(&remote_time)); | 76 | printf("%s", ctime(&remote_time)); |
77 | 77 | ||
78 | return EXIT_SUCCESS; | 78 | return EXIT_SUCCESS; |