libbb: introduce and use strftime_[YYYYMMDD]HHMMSS()
[oweals/busybox.git] / networking / ntpd_simple.c
index 55bded8ffe38b05335cb572fb245eae16e364bb3..3e7fc47199667b73cc4199531ee761d8f5dc8bfa 100644 (file)
@@ -378,7 +378,7 @@ step_time_once(double offset)
                bb_perror_msg_and_die("settimeofday");
 
        tval = tv.tv_sec;
-       strftime(buf, sizeof(buf), "%a %b %e %H:%M:%S %Z %Y", localtime(&tval));
+       strftime_YYYYMMDDHHMMSS(buf, sizeof(buf), &tval);
 
        bb_error_msg("setting clock to %s (offset %fs)", buf, offset);