]> git.saurik.com Git - android/aapt.git/commitdiff
Merge "Fix length of pattern." DO NOT MERGE.
authorYing Wang <wangying@google.com>
Tue, 22 May 2012 18:24:22 +0000 (11:24 -0700)
committerRaphael Moll <ralf@android.com>
Thu, 24 May 2012 18:07:14 +0000 (11:07 -0700)
After skipping * with "token++", the length should decrease by 1 as
well.

(merged from 996b073e813ba1a22a13282ccdebb664f14ba898)

Change-Id: Ie6232ef603bb31e25e03b926e6c1bb92ac34902d

AaptAssets.cpp

index eba77c258acbf41367bb77dc8cadd674f3308027..7d735ad424e6b38889d05b62946c80fe718c6dd9 100644 (file)
@@ -122,6 +122,7 @@ static bool isHidden(const char *root, const char *path)
         if (token[0] == '*') {
             // Match *suffix
             token++;
         if (token[0] == '*') {
             // Match *suffix
             token++;
+            n--;
             if (n <= plen) {
                 ignore = strncasecmp(token, path + plen - n, n) == 0;
             }
             if (n <= plen) {
                 ignore = strncasecmp(token, path + plen - n, n) == 0;
             }