1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-09-01 05:02:03 +03:00
2002-05-21  Isamu Hasegawa  <isamu@yamato.ibm.com>

	* posix/regex.c: Define `inline' as a macro into nothing for the
	compilers which lack the keyword.
	* posix/regex.h: (RE_SYNTAX_GNU_AWK): Remove RE_CONTEXT_INVALID_OPS
	for the compatibility of gawk.
	* posix/regcomp.c: Add fake implementation of isblank() for the
	environments which lack the function.
	Don't use free_charset() in case of non-i18n envs.
	(build_range_exp): Don't use i18n related code in case of non-i18n
	envs.
	(build_collating_symbol): Likewise.
	(build_equiv_class): Likewise.
	(build_charclass): Likewise.
	(re_compile_fastmap_iter): Likewise.
	(parse_bracket_exp): Likewise.
	(build_word_op): Likewise.
	(regfree): Don't use free_charset() in case of non-i18n envs.
	* posix/regex_internal.h: Remove COMPLEX_BRACKET from
	re_token_type_t in case of non-i18n envs.
	Don't define re_charset_t in case of non-i18n envs.
	Change the type of wcs of re_string_t from wchar_t to wint_t,
	since we store also WEOF.
	* posix/regex_internal.c: (re_string_realloc_buffers): Change
	the type of wcs of re_string_t from wchar_t to wint_t.
	(re_string_reconstruct): Likewise.
	(create_ci_newstate): Don't use i18n related code in case of
	non-i18n envs.
	(create_cd_newstate): Likewise.

2002-05-24  Ulrich Drepper  <drepper@redhat.com>

	* iconv/loop.c: Fix typo.

2002-05-23  Jakub Jelinek  <jakub@redhat.com>

	* inet/ether_line.c (ether_line): Fix a typo causing only
	lower 4 bits of each ethernet address byte being assigned.
	Don't modify what line points to.
	* inet/tst-ether_aton.c (main): Add ether_line tests.

2002-05-23  Marcus Brinkmann  <marcus@gnu.org>

	* manual/filesys.texi: Don't make readlink example leak memory
	when readlink fails.
This commit is contained in:
Ulrich Drepper
2002-05-24 08:49:00 +00:00
parent 12b7f470d2
commit c0a0f9a32c
12 changed files with 322 additions and 88 deletions

View File

@@ -169,7 +169,7 @@ re_string_realloc_buffers (pstr, new_buf_len)
#ifdef RE_ENABLE_I18N
if (MB_CUR_MAX > 1)
{
pstr->wcs = re_realloc (pstr->wcs, wchar_t, new_buf_len);
pstr->wcs = re_realloc (pstr->wcs, wint_t, new_buf_len);
if (BE (pstr->wcs == NULL, 0))
return REG_ESPACE;
}
@@ -436,7 +436,7 @@ re_string_reconstruct (pstr, idx, eflags, newline)
#ifdef RE_ENABLE_I18N
if (MB_CUR_MAX > 1)
memmove (pstr->wcs, pstr->wcs + offset,
(pstr->valid_len - offset) * sizeof (wchar_t));
(pstr->valid_len - offset) * sizeof (wint_t));
#endif /* RE_ENABLE_I18N */
if (MBS_ALLOCATED (pstr))
memmove (pstr->mbs, pstr->mbs + offset,
@@ -1166,9 +1166,11 @@ create_ci_newstate (dfa, nodes, hash)
/* If the state has the halt node, the state is a halt state. */
else if (type == END_OF_RE)
newstate->halt = 1;
#ifdef RE_ENABLE_I18N
else if (type == COMPLEX_BRACKET
|| (type == OP_PERIOD && MB_CUR_MAX > 1))
newstate->accept_mb = 1;
#endif /* RE_ENABLE_I18N */
else if (type == OP_BACK_REF)
newstate->has_backref = 1;
else if (type == ANCHOR || OP_CONTEXT_NODE)
@@ -1213,9 +1215,11 @@ create_cd_newstate (dfa, nodes, context, hash)
/* If the state has the halt node, the state is a halt state. */
else if (type == END_OF_RE)
newstate->halt = 1;
#ifdef RE_ENABLE_I18N
else if (type == COMPLEX_BRACKET
|| (type == OP_PERIOD && MB_CUR_MAX > 1))
newstate->accept_mb = 1;
#endif /* RE_ENABLE_I18N */
else if (type == OP_BACK_REF)
newstate->has_backref = 1;
else if (type == ANCHOR)
@@ -1228,9 +1232,11 @@ create_cd_newstate (dfa, nodes, context, hash)
newstate->halt = 1;
else if (ctype == OP_BACK_REF)
newstate->has_backref = 1;
#ifdef RE_ENABLE_I18N
else if (ctype == COMPLEX_BRACKET
|| (type == OP_PERIOD && MB_CUR_MAX > 1))
newstate->accept_mb = 1;
#endif /* RE_ENABLE_I18N */
}
if (constraint)