From: Jim Meyering Date: Fri, 11 Dec 1998 13:37:52 +0000 (+0000) Subject: (main): Arrange to exit unsuccessfully when stime fails. X-Git-Tag: FILEUTILS-4_1-b1~45 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a17cdb11731e3a557f3274ae566c39bd137d0640;p=thirdparty%2Fcoreutils.git (main): Arrange to exit unsuccessfully when stime fails. From Andreas Schwab. --- diff --git a/src/date.c b/src/date.c index bf5b565b46..79eaf4f036 100644 --- a/src/date.c +++ b/src/date.c @@ -344,7 +344,10 @@ argument must be a format string beginning with `+'."), /* Set the system clock to the specified date, then regardless of the success of that operation, format and print that date. */ if (stime (&when) == -1) - error (0, errno, _("cannot set date")); + { + error (0, errno, _("cannot set date")); + status = 1; + } } /* When given a universal time option, set TZ to UTC0 after