X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=common-src%2Fmatch-test.c;h=9be05efbe45674cb9a0bacdf8139f8407c2b26a6;hb=refs%2Ftags%2Fupstream%2F3.3.1;hp=8737e56584829f1f101625be1d8cee42eb365c14;hpb=cd0b924f27312d57bd42f6c4fae2b795139e2d0b;p=debian%2Famanda diff --git a/common-src/match-test.c b/common-src/match-test.c index 8737e56..9be05ef 100644 --- a/common-src/match-test.c +++ b/common-src/match-test.c @@ -706,8 +706,10 @@ test_match_disk(void) { "\\\\\\\\windows\\\\share", "\\\\windows\\share", TRUE }, /* other expressions */ - { "^local", "/local", TRUE }, - { "^local", "/local/vore", TRUE }, + { "^local", "/local", FALSE }, + { "^/local", "/local", TRUE }, + { "^local", "/local/vore", FALSE }, + { "^/local", "/local/vore", TRUE }, { "^local", "/usr/local", FALSE }, { "local/bin", "/local/bin", TRUE }, @@ -740,7 +742,41 @@ test_match_disk(void) { "/usr\\/bin", "/usr/bin", TRUE }, { "^/usr\\/bin$", "/usr/bin", TRUE }, { "\\/usr\\/bin", "/usr/bin", FALSE }, - { "^\\/usr\\/bin$", "/usr/bin", FALSE }, + { "^\\/usr\\/bin$", "/usr/bin", TRUE }, + { "/usr\\/bin\\/", "/usr/bin/", TRUE }, + { "^/usr\\/bin\\/$", "/usr/bin/", TRUE }, + { "\\/usr\\/bin\\/", "/usr/bin/", FALSE }, + { "^\\/usr\\/bin\\/$", "/usr/bin/", TRUE }, + + { "oracle", "oracle", TRUE }, + { "oracle", "/oracle", TRUE }, + { "oracle", "oracle/", TRUE }, + { "oracle", "/oracle/", TRUE }, + { "/oracle", "oracle", TRUE }, + { "/oracle", "/oracle", TRUE }, + { "/oracle", "oracle/", TRUE }, + { "/oracle", "/oracle/", TRUE }, + { "^oracle", "oracle", TRUE }, + { "^oracle", "/oracle", FALSE }, + { "^oracle", "oracle/", TRUE }, + { "^oracle", "/oracle/", FALSE }, + { "^/oracle", "oracle", FALSE }, + { "^/oracle", "/oracle", TRUE }, + { "^/oracle", "oracle/", FALSE }, + { "^/oracle", "/oracle/", TRUE }, + + { "oracle", "oracle", TRUE }, + { "oracle", "/oracle", TRUE }, + { "oracle", "oracle/", TRUE }, + { "oracle", "/oracle/", TRUE }, + { "oracle$", "oracle", TRUE }, + { "oracle$", "/oracle", TRUE }, + { "oracle$", "oracle/", FALSE }, + { "oracle$", "/oracle/", FALSE }, + { "oracle/$", "oracle", FALSE }, + { "oracle/$", "/oracle", FALSE }, + { "oracle/$", "oracle/", TRUE }, + { "oracle/$", "/oracle/", TRUE }, { NULL, NULL, FALSE }, }, *t;