Make sure that %r honors the LC_TIME t_fmt_ampm.
authorPeter Avalos <pavalos@theshell.com>
Fri, 16 Jan 2009 00:37:18 +0000 (19:37 -0500)
committerPeter Avalos <pavalos@theshell.com>
Tue, 7 Apr 2009 07:08:31 +0000 (21:08 -1000)
Obtained-from: NetBSD

lib/libc/stdtime/strftime.c

index e64e04a..ca1c056 100644 (file)
@@ -259,7 +259,8 @@ label:
                                pt = _fmt("%H:%M", t, pt, ptlim, warnp);
                                continue;
                        case 'r':
-                               pt = _fmt("%I:%M:%S %p", t, pt, ptlim, warnp);
+                               pt = _fmt(Locale->t_fmt_ampm, t, pt, ptlim,
+                                       warnp);
                                continue;
                        case 'S':
                                pt = _conv(t->tm_sec, "%02d", pt, ptlim);