commit bash-20120427 snapshot

This commit is contained in:
Chet Ramey
2012-05-02 08:33:16 -04:00
parent e107650cbf
commit 8cb3d56718
6 changed files with 1030 additions and 7 deletions
+4 -4
View File
@@ -145,7 +145,7 @@ iso_8601_2000_year(char *buf, int year, size_t fw)
char sign = '\0';
if (year >= -9999 && year <= 9999) {
sprintf(buf, "%0*d", fw, year);
sprintf(buf, "%0*d", (int) fw, year);
return;
}
@@ -361,7 +361,7 @@ strftime(char *s, size_t maxsize, const char *format, const struct tm *timeptr)
fw = max(fw, min_fw);
sprintf(tbuf, flag
? "%+0*ld"
: "%0*ld", fw,
: "%0*ld", (int) fw,
(timeptr->tm_year + 1900L) / 100);
} else
#endif /* POSIX_2008 */
@@ -440,7 +440,7 @@ strftime(char *s, size_t maxsize, const char *format, const struct tm *timeptr)
fw = max(fw, min_fw);
sprintf(tbuf, flag
? "%+0*ld"
: "%0*ld", fw,
: "%0*ld", (int) fw,
y);
} else
#endif /* POSIX_2008 */
@@ -577,7 +577,7 @@ strftime(char *s, size_t maxsize, const char *format, const struct tm *timeptr)
fw = max(fw, min_fw);
sprintf(tbuf, flag
? "%+0*ld"
: "%0*ld", fw,
: "%0*ld", (int) fw,
1900L + timeptr->tm_year);
} else
#endif /* POSIX_2008 */
+1006
View File
File diff suppressed because it is too large Load Diff