aboutsummaryrefslogtreecommitdiff
path: root/stdlib
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib')
-rw-r--r--stdlib/strfmon.c3
-rw-r--r--stdlib/strfmon_l.c8
2 files changed, 6 insertions, 5 deletions
diff --git a/stdlib/strfmon.c b/stdlib/strfmon.c
index 01980d3e15..3058b3eed1 100644
--- a/stdlib/strfmon.c
+++ b/stdlib/strfmon.c
@@ -30,7 +30,8 @@ __strfmon (char *s, size_t maxsize, const char *format, ...)
va_start (ap, format);
- ssize_t res = __vstrfmon_l (s, maxsize, _NL_CURRENT_LOCALE, format, ap);
+ ssize_t res = __vstrfmon_l_internal (s, maxsize, _NL_CURRENT_LOCALE,
+ format, ap, 0);
va_end (ap);
diff --git a/stdlib/strfmon_l.c b/stdlib/strfmon_l.c
index cd3796ced9..5293104400 100644
--- a/stdlib/strfmon_l.c
+++ b/stdlib/strfmon_l.c
@@ -76,8 +76,8 @@
too. Some of the information contradicts the information which can
be specified in format string. */
ssize_t
-__vstrfmon_l (char *s, size_t maxsize, locale_t loc, const char *format,
- va_list ap)
+__vstrfmon_l_internal (char *s, size_t maxsize, locale_t loc,
+ const char *format, va_list ap, unsigned int flags)
{
struct __locale_data *current = loc->__locales[LC_MONETARY];
_IO_strfile f;
@@ -268,7 +268,7 @@ __vstrfmon_l (char *s, size_t maxsize, locale_t loc, const char *format,
if (*fmt == 'L')
{
++fmt;
- if (!__ldbl_is_dbl)
+ if (__glibc_likely ((flags & STRFMON_LDBL_IS_DBL) == 0))
is_long_double = 1;
}
@@ -608,7 +608,7 @@ ___strfmon_l (char *s, size_t maxsize, locale_t loc, const char *format, ...)
va_start (ap, format);
- ssize_t res = __vstrfmon_l (s, maxsize, loc, format, ap);
+ ssize_t res = __vstrfmon_l_internal (s, maxsize, loc, format, ap, 0);
va_end (ap);