diff options
Diffstat (limited to 'libcutils/tzstrftime.c')
-rw-r--r-- | libcutils/tzstrftime.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/libcutils/tzstrftime.c b/libcutils/tzstrftime.c index 29c50154a..e37d79ae6 100644 --- a/libcutils/tzstrftime.c +++ b/libcutils/tzstrftime.c @@ -172,10 +172,17 @@ label: pt, ptlim, modifier); continue; case 'B': - pt = _add((t->tm_mon < 0 || - t->tm_mon >= MONSPERYEAR) ? - "?" : Locale->month[t->tm_mon], - pt, ptlim, modifier); + if (modifier == '-') { + pt = _add((t->tm_mon < 0 || + t->tm_mon >= MONSPERYEAR) ? + "?" : Locale->standalone_month[t->tm_mon], + pt, ptlim, modifier); + } else { + pt = _add((t->tm_mon < 0 || + t->tm_mon >= MONSPERYEAR) ? + "?" : Locale->month[t->tm_mon], + pt, ptlim, modifier); + } continue; case 'b': case 'h': |