Age | Commit message (Collapse) | Author |
|
In certain cases, fnmatch() could access the next byte beyond the end of
he passed pattern. A triggering pattern to match is the following
invocation:
fnmatch("[A-Z[.", "F", 0)
The normal A-Z group match gets us to fnmatch_loop.c:421 and then to
fnmatch_loop:599. The F in the filaname matches this expression and
we end up in fnmatch_loop:867 which handles skipping the rest of a
bracked expression that already matched. Here we enter the case where
the next chars to parse are a collating symbol starting with "[."
(fnmatch_loop:918). Currently the p pointer is then advanced by one,
moving it beyond the "." and to the \0 byte of the pattern string
(fnmatch_loop:920). Inside the while loop the pointer is then
incremented again and immediately dereferenced, reaching beyond the
end of the pattern string.
The increment before the while loop must be removed, because only inside
the while loop (after the other increment) a check for the end of the
string is performend. This is sufficient and the check of the end of
the collating symbol is only performed if p[1] is at most the
terminating \0 byte.
Signed-Off-By: Frank Mehnert <frank.mehnert@kernkonzept.com>
|
|
Signed-off-by: Yann Sionneau <ysionneau@kalray.eu>
|
|
Fixes this:
In file included from libc/misc/fnmatch/fnmatch.c:235:0:
libc/misc/fnmatch/fnmatch_loop.c: In function 'internal_fnmatch':
libc/misc/fnmatch/fnmatch_loop.c:207:21: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
CHAR *p_init = p;
^
libc/misc/fnmatch/fnmatch_loop.c:208:21: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
CHAR *n_init = n;
Signed-off-by: Yann Sionneau <ysionneau@kalray.eu>
|
|
|
|
Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
|
|
Originally fixed in GNU libc by:
commit 794c3ad3a405697e2663b00f616e319383b9bb7d
Author: Ulrich Drepper <drepper@gmail.com>
Date: Fri Jan 14 08:06:22 2011 -0500
Reported-by: Denys Vlasenko <vda.linux@googlemail.com>
via busybox mailinglist.
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
This matches a similar change made to glibc.
No functional changes here.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
sed -i -e '/Experimentally off - /d' $(grep -rl "Experimentally off - " *)
sed -i -e '/^\/\*[[:space:]]*libc_hidden_proto(/d' $(grep -rl "libc_hidden_proto" *)
should be a nop
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Handle O=
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
Once again all of these reduce the noise from gcc-4.4.
Replaces a few more (USE_TLS && HAVE___THREAD) with USE___THREAD while we need
to mess with them for this anyhow.
Signed-off-by: Ron Lee <ron@debian.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
|
|
|
|
Appears to build fine (several .configs tried)
|
|
|
|
|
|
|
|
remove a few duplicate includes of unistd.h
|
|
|
|
- 79 0 28 107 6b libc/inet/rpc/create_xid.o
+ 76 0 25 101 65 libc/inet/rpc/create_xid.o
- 126 0 4 130 82 libc/misc/assert/__assert.o
+ 123 0 1 124 7c libc/misc/assert/__assert.o
- 648 4 24 676 2a4 libc/misc/internals/__uClibc_main.o
+ 645 4 21 670 29e libc/misc/internals/__uClibc_main.o
- 230 0 4 234 ea libc/stdlib/abort.o
+ 216 0 1 217 d9 libc/stdlib/abort.o
- 129 0 4 133 85 libc/termios/tcgetsid.o
+ 126 0 1 127 7f libc/termios/tcgetsid.o
|
|
|
|
in string.h and strings.h. This caught unguarded string ops in
libc/inet/ethers.c __ether_line_w() function.
I will wait for fallout reports for a week or so,
then continue converting more libc_hidden_proto's.
|
|
I had clearly run search/replace on that were cluttering things up.
|
|
|
|
|
|
libc.a/libc.so, the diffs go into libc-static-y/libc-shared-y exclusively, add IMA to libc, don't use any MSRC anymore
|
|
|
|
is a useless attempt
|
|
gone from libc. The remaining are left as exercise for others ;-)
|
|
|
|
missing headers, other jump relocs removed
|
|
|
|
|
|
|
|
This patch is wrong and breaks (at least) building a static libc. The
$(MISC_FNMATCH_OBJ) file still uses the .c extension, thus isn't built
at all and eg. strip'ping the .c file fails, breaking the build.
|
|
UCLIBC_HAS_LOCALE, making the new object about 5k, else it would be 10k
|
|
|
|
|
|
|
|
|
|
|
|
libc-a-y for objects that go into static libs, changing their suffix to .os, of they should be PIC
|