mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-28 00:21:52 +03:00
Update.
* stdlib/strfmon.c: Don't report an error if final NUL is at the end of the buffer. Set errno correctly if floating-point number would overflow buffer. * posix/regex.h: Update comment of RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
This commit is contained in:
@ -1,5 +1,12 @@
|
|||||||
2000-01-19 Ulrich Drepper <drepper@cygnus.com>
|
2000-01-19 Ulrich Drepper <drepper@cygnus.com>
|
||||||
|
|
||||||
|
* stdlib/strfmon.c: Don't report an error if final NUL is at the
|
||||||
|
end of the buffer. Set errno correctly if floating-point number
|
||||||
|
would overflow buffer.
|
||||||
|
|
||||||
|
* posix/regex.h: Update comment of
|
||||||
|
RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
|
||||||
|
|
||||||
* locale/weight.h (findidx): Little optimization. Correctly return
|
* locale/weight.h (findidx): Little optimization. Correctly return
|
||||||
offset in indirect table.
|
offset in indirect table.
|
||||||
* locale/programs/ld-collate.c (struct element_t): Add mblast
|
* locale/programs/ld-collate.c (struct element_t): Add mblast
|
||||||
|
@ -226,8 +226,8 @@ extern reg_syntax_t re_syntax_options;
|
|||||||
| RE_NO_BK_PARENS | RE_NO_BK_VBAR \
|
| RE_NO_BK_PARENS | RE_NO_BK_VBAR \
|
||||||
| RE_CONTEXT_INVALID_OPS | RE_UNMATCHED_RIGHT_PAREN_ORD)
|
| RE_CONTEXT_INVALID_OPS | RE_UNMATCHED_RIGHT_PAREN_ORD)
|
||||||
|
|
||||||
/* Differs from ..._POSIX_EXTENDED in that RE_CONTEXT_INVALID_OPS
|
/* Differs from ..._POSIX_EXTENDED in that RE_CONTEXT_INDEP_OPS is
|
||||||
replaces RE_CONTEXT_INDEP_OPS and RE_NO_BK_REFS is added. */
|
removed and RE_NO_BK_REFS is added. */
|
||||||
#define RE_SYNTAX_POSIX_MINIMAL_EXTENDED \
|
#define RE_SYNTAX_POSIX_MINIMAL_EXTENDED \
|
||||||
(_RE_SYNTAX_POSIX_COMMON | RE_CONTEXT_INDEP_ANCHORS \
|
(_RE_SYNTAX_POSIX_COMMON | RE_CONTEXT_INDEP_ANCHORS \
|
||||||
| RE_CONTEXT_INVALID_OPS | RE_NO_BK_BRACES \
|
| RE_CONTEXT_INVALID_OPS | RE_NO_BK_BRACES \
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Formatting a monetary value according to the current locale.
|
/* Formatting a monetary value according to the current locale.
|
||||||
Copyright (C) 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
|
Copyright (C) 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
Contributed by Ulrich Drepper <drepper@cygnus.com>
|
Contributed by Ulrich Drepper <drepper@cygnus.com>
|
||||||
and Jochen Hein <Jochen.Hein@informatik.TU-Clausthal.de>, 1996.
|
and Jochen Hein <Jochen.Hein@informatik.TU-Clausthal.de>, 1996.
|
||||||
@ -465,7 +465,10 @@ __strfmon_l (char *s, size_t maxsize, __locale_t loc, const char *format, ...)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (s[maxsize - 1] != '\0')
|
if (s[maxsize - 1] != '\0')
|
||||||
return -1;
|
{
|
||||||
|
__set_errno (E2BIG);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
dest += done;
|
dest += done;
|
||||||
|
|
||||||
@ -521,9 +524,9 @@ __strfmon_l (char *s, size_t maxsize, __locale_t loc, const char *format, ...)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Terminate the string. */
|
/* Terminate the string. */
|
||||||
out_char ('\0');
|
*dest = '\0';
|
||||||
|
|
||||||
va_end (ap);
|
va_end (ap);
|
||||||
|
|
||||||
return dest - s - 1;
|
return dest - s;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user