summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2009-10-05 07:13:15 +0000
committeredwin <edwin@FreeBSD.org>2009-10-05 07:13:15 +0000
commit1b3420e9d42bd8cce1889fab5c1da7feb69a036c (patch)
treed96da4bc192b31d08a36e03e614bda8f6dc8dc48
parent5ecdf4b5b2855eebecc575710a4fa7b821df8de2 (diff)
downloadFreeBSD-src-1b3420e9d42bd8cce1889fab5c1da7feb69a036c.zip
FreeBSD-src-1b3420e9d42bd8cce1889fab5c1da7feb69a036c.tar.gz
Modified locale(1) to be able to show the altmon_X fields and the [cxX]_fmt's.
Also modify the "-k list" option to display only fields with a certain prefix. MFC after: 1 week
-rw-r--r--lib/libc/locale/nl_langinfo.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/libc/locale/nl_langinfo.c b/lib/libc/locale/nl_langinfo.c
index 9bd5082..26ca025 100644
--- a/lib/libc/locale/nl_langinfo.c
+++ b/lib/libc/locale/nl_langinfo.c
@@ -93,6 +93,12 @@ nl_langinfo(nl_item item)
case ABMON_9: case ABMON_10: case ABMON_11: case ABMON_12:
ret = (char*) __get_current_time_locale()->mon[_REL(ABMON_1)];
break;
+ case ALTMON_1: case ALTMON_2: case ALTMON_3: case ALTMON_4:
+ case ALTMON_5: case ALTMON_6: case ALTMON_7: case ALTMON_8:
+ case ALTMON_9: case ALTMON_10: case ALTMON_11: case ALTMON_12:
+ ret = (char*)
+ __get_current_time_locale()->alt_month[_REL(ALTMON_1)];
+ break;
case ERA:
/* XXX: need to be implemented */
ret = "";
OpenPOWER on IntegriCloud