This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/14185] fnmatch() fails when '*' wildcard is applied on the file name containing multi-byte character(s)
- From: "bugdal at aerifal dot cx" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: Fri, 01 Jun 2012 02:32:05 +0000
- Subject: [Bug libc/14185] fnmatch() fails when '*' wildcard is applied on the file name containing multi-byte character(s)
- Auto-submitted: auto-generated
- References: <bug-14185-131@http.sourceware.org/bugzilla/>
http://sourceware.org/bugzilla/show_bug.cgi?id=14185
--- Comment #4 from Rich Felker <bugdal at aerifal dot cx> 2012-06-01 02:32:05 UTC ---
This patch fixes the bug in the test case, but I'm not convinced that it
doesn't create other (possibly much worse!) bugs in the process. For instance,
the pattern "[Ã]*" should not match "\xa1.txt", but with fallback to treating
everything as bytes, it does match. Basically this patch would make "rm -f
pattern" potentially delete lots of files with illegal byte sequences in their
names whenever pattern contains a bracket expression with multibyte characters
in it. (Note that the effect becomes even more severe with a range expression
like [Ã-Ã]...)
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.