projects
/
platform
/
upstream
/
glibc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0c02c85
)
(build_range_exp) [!_LIBC]: Check validity of collation elements.
author
Ulrich Drepper
<drepper@redhat.com>
Fri, 30 Jan 2004 05:19:45 +0000
(
05:19
+0000)
committer
Ulrich Drepper
<drepper@redhat.com>
Fri, 30 Jan 2004 05:19:45 +0000
(
05:19
+0000)
posix/regcomp.c
patch
|
blob
|
history
diff --git
a/posix/regcomp.c
b/posix/regcomp.c
index
4f53944
..
33ca7c9
100644
(file)
--- a/
posix/regcomp.c
+++ b/
posix/regcomp.c
@@
-2560,6
+2560,8
@@
build_range_exp (sbcset, start_elem, end_elem)
? __btowc (start_ch) : start_elem->opr.wch);
end_wc = ((end_elem->type == SB_CHAR || end_elem->type == COLL_SYM)
? __btowc (end_ch) : end_elem->opr.wch);
+ if (start_wc == WEOF || end_wc == WEOF)
+ return REG_ECOLLATE;
cmp_buf[0] = start_wc;
cmp_buf[4] = end_wc;
if (wcscoll (cmp_buf, cmp_buf + 4) > 0)