mirror of
git://sourceware.org/git/glibc.git
synced 2025-01-18 12:16:13 +08:00
Update.
* posix/regex.c (compile_range): Transliate range start and end characters to avoid empty range in case of REG_ICASE [PR libc/1842].
This commit is contained in:
parent
cfd57cdc0f
commit
f6cfb13f55
@ -1,5 +1,8 @@
|
|||||||
2000-08-02 Ulrich Drepper <drepper@redhat.com>
|
2000-08-02 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* posix/regex.c (compile_range): Transliate range start and end
|
||||||
|
characters to avoid empty range in case of REG_ICASE [PR libc/1842].
|
||||||
|
|
||||||
* sysdeps/unix/sysv/linux/ia64/bits/resource.h: Don't include
|
* sysdeps/unix/sysv/linux/ia64/bits/resource.h: Don't include
|
||||||
asm/resource.h.
|
asm/resource.h.
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
void
|
void
|
||||||
write_data (FILE * stream)
|
write_data (FILE * stream)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
@ -23,11 +23,16 @@ main (void)
|
|||||||
output = popen ("more", "w");
|
output = popen ("more", "w");
|
||||||
if (!output)
|
if (!output)
|
||||||
{
|
{
|
||||||
fprintf (stderr, "Could not run more.\n");
|
fprintf (stderr,
|
||||||
|
"incorrect parameters or too many files.\n");
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
write_data (output);
|
write_data (output);
|
||||||
pclose (output);
|
if (pclose (output) != 0)
|
||||||
|
{
|
||||||
|
fprintf (stderr,
|
||||||
|
"Could not run more or other error.\n");
|
||||||
|
}
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
/*@end group*/
|
/*@end group*/
|
||||||
|
@ -3518,9 +3518,9 @@ compile_range (range_start_char, p_ptr, pend, translate, syntax, b)
|
|||||||
|
|
||||||
/* Fetch the endpoints without translating them; the
|
/* Fetch the endpoints without translating them; the
|
||||||
appropriate translation is done in the bit-setting loop below. */
|
appropriate translation is done in the bit-setting loop below. */
|
||||||
range_start[0] = range_start_char;
|
range_start[0] = TRANSLATE (range_start_char);
|
||||||
range_start[1] = '\0';
|
range_start[1] = '\0';
|
||||||
range_end[0] = p[0];
|
range_end[0] = TRANSLATE (p[0]);
|
||||||
range_end[1] = '\0';
|
range_end[1] = '\0';
|
||||||
|
|
||||||
/* Have to increment the pointer into the pattern string, so the
|
/* Have to increment the pointer into the pattern string, so the
|
||||||
|
Loading…
Reference in New Issue
Block a user