]> sourceware.org Git - glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Wed, 28 Mar 2001 06:25:09 +0000 (06:25 +0000)
committerUlrich Drepper <drepper@redhat.com>
Wed, 28 Mar 2001 06:25:09 +0000 (06:25 +0000)
* posix/fnmatch_loop.c (FCT): Handle !() after * special like @()
and +().
* posix/tst-fnmatch.input: Add test cases for matching empty strings.

ChangeLog
posix/fnmatch_loop.c
posix/tst-fnmatch.input

index b774a2f16677af9cb0b9761522dff4a043650027..296e8ad548e359df876699d45ab20b1731357e11 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2001-03-27  Ulrich Drepper  <drepper@redhat.com>
 
+       * posix/fnmatch_loop.c (FCT): Handle !() after * special like @()
+       and +().
+       * posix/tst-fnmatch.input: Add test cases for matching empty strings.
+
        * sysdeps/ieee754/dbl-64/endian.h: Removed.  Move definitions...
        * include/endian.h: ...to here.
 
index 20ae0e366965c4dc712b560984a64355b4fc88a9..fd25853c3120a412969cb4531772c9b6afc905b8 100644 (file)
@@ -164,8 +164,8 @@ FCT (pattern, string, string_end, no_leading_period, flags)
 
              if (c == L('[')
                  || (__builtin_expect (flags & FNM_EXTMATCH, 0) != 0
-                     /* XXX Do we have to add '!'?  */
-                     && (c == L('@') || c == L('+')) && *p == L('(')))
+                     && (c == L('@') || c == L('+') || c == L('!'))
+                     && *p == L('(')))
                {
                  int flags2 = ((flags & FNM_FILE_NAME)
                                ? flags : (flags & ~FNM_PERIOD));
index 219124556e94d4c3bf0c0f2c8081e06e4705d534..e448576be16fecc48c681d829a00654180f00fbe 100644 (file)
@@ -713,5 +713,9 @@ C           "["                     "!([!]a[])"            0       EXTMATCH
 C              "]"                     "!([!]a[])"            0       EXTMATCH
 C              ")"                     "*([)])"               0       EXTMATCH
 C              "*"                     "*([*(])"              0       EXTMATCH
-C              "abcd"                  "*!(|a)cd"             NOMATCH EXTMATCH
+C              "abcd"                  "*!(|a)cd"             0       EXTMATCH
 C              "ab/.a"                 "+([abc])/*"           NOMATCH EXTMATCH|PATHNAME|PERIOD
+C              ""                      ""                     0
+C              ""                      ""                     0       EXTMATCH
+C              ""                      "*([abc])"             0       EXTMATCH
+C              ""                      "?([abc])"             0       EXTMATCH
This page took 0.051718 seconds and 5 git commands to generate.