diff options
author | Rich Felker <dalias@aerifal.cx> | 2014-07-26 04:43:50 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2014-07-26 04:43:50 -0400 |
commit | 0206f596d5156af560e8af10e950d3cb2f29b73d (patch) | |
tree | a27c52c209f3b5846bae89e6fe2a4f35c75594cb /src/locale | |
parent | a19cd2b64aabee4ae3c80bcf4ba8da26fba560e4 (diff) | |
download | musl-0206f596d5156af560e8af10e950d3cb2f29b73d.tar.gz musl-0206f596d5156af560e8af10e950d3cb2f29b73d.tar.bz2 musl-0206f596d5156af560e8af10e950d3cb2f29b73d.tar.xz musl-0206f596d5156af560e8af10e950d3cb2f29b73d.zip |
add missing yes/no strings to nl_langinfo
these were removed from the standard but still offered as an extension
in langinfo.h, so nl_langinfo should support them.
Diffstat (limited to 'src/locale')
-rw-r--r-- | src/locale/langinfo.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/locale/langinfo.c b/src/locale/langinfo.c index 657dd9c4..aa0e8de6 100644 --- a/src/locale/langinfo.c +++ b/src/locale/langinfo.c @@ -24,7 +24,7 @@ static const char c_time[] = "%a %b %e %T %Y\0" "%H:%M:%S"; -static const char c_messages[] = "^[yY]\0" "^[nN]"; +static const char c_messages[] = "^[yY]\0" "^[nN]\0" "yes\0" "no"; static const char c_numeric[] = ".\0" ""; char *__nl_langinfo_l(nl_item item, locale_t loc) @@ -49,7 +49,7 @@ char *__nl_langinfo_l(nl_item item, locale_t loc) str = ""; break; case LC_MESSAGES: - if (idx > 1) return NULL; + if (idx > 3) return NULL; str = c_messages; break; default: |