1
0
Эх сурвалжийг харах

fix strftime %s not to zero pad with default width=2

(cherry picked from commit ac0acd569e01735fc6052d43fdf57f3a07c93f3d)
Szabolcs Nagy 11 жил өмнө
parent
commit
45619f5c23
1 өөрчлөгдсөн 1 нэмэгдсэн , 0 устгасан
  1. 1 0
      src/time/strftime.c

+ 1 - 0
src/time/strftime.c

@@ -126,6 +126,7 @@ const char *__strftime_fmt_1(char (*s)[100], size_t *l, int f, const struct tm *
 		goto recu_strftime;
 	case 's':
 		val = __tm_to_secs(tm) + tm->__tm_gmtoff;
+		width = 1;
 		goto number;
 	case 'S':
 		val = tm->tm_sec;