summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-05-04 20:53:33 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-05-06 07:51:24 +0200
commit3892112e7b3143f808932771a7b71f4fd335f8cb (patch)
treefa5254ec26d309e3bda8c8c502363e36feb7f8f9 /source4
parentcad704e8368f6aba28889966a7382afc8b738928 (diff)
downloadsamba-3892112e7b3143f808932771a7b71f4fd335f8cb.tar.gz
samba-3892112e7b3143f808932771a7b71f4fd335f8cb.tar.bz2
samba-3892112e7b3143f808932771a7b71f4fd335f8cb.zip
lib/util Rename ms_fnmatch() to ms_fnmatch_protocol() to avoid dup symbol
This verison of the function takes a protcol as argument to determine matching rules. Andrew Bartlett
Diffstat (limited to 'source4')
-rw-r--r--source4/client/client.c4
-rw-r--r--source4/ntvfs/cifs_posix_cli/svfs_util.c2
-rw-r--r--source4/ntvfs/posix/pvfs_dirlist.c8
-rw-r--r--source4/ntvfs/simple/svfs_util.c2
-rw-r--r--source4/torture/masktest.c2
5 files changed, 9 insertions, 9 deletions
diff --git a/source4/client/client.c b/source4/client/client.c
index a226982296..27535a1cd3 100644
--- a/source4/client/client.c
+++ b/source4/client/client.c
@@ -309,12 +309,12 @@ static bool mask_match(struct smbcli_state *c, const char *string,
return false;
if (is_case_sensitive)
- return ms_fnmatch(pattern, string,
+ return ms_fnmatch_protocol(pattern, string,
c->transport->negotiate.protocol) == 0;
p2 = strlower_talloc(NULL, pattern);
s2 = strlower_talloc(NULL, string);
- ret = ms_fnmatch(p2, s2, c->transport->negotiate.protocol) == 0;
+ ret = ms_fnmatch_protocol(p2, s2, c->transport->negotiate.protocol) == 0;
talloc_free(p2);
talloc_free(s2);
diff --git a/source4/ntvfs/cifs_posix_cli/svfs_util.c b/source4/ntvfs/cifs_posix_cli/svfs_util.c
index 128440c1ea..f351c5840e 100644
--- a/source4/ntvfs/cifs_posix_cli/svfs_util.c
+++ b/source4/ntvfs/cifs_posix_cli/svfs_util.c
@@ -104,7 +104,7 @@ struct cifspsx_dir *cifspsx_list_unix(TALLOC_CTX *mem_ctx, struct ntvfs_request
if (!low_name) { continue; }
/* check it matches the wildcard pattern */
- if (ms_fnmatch(low_mask, low_name, PROTOCOL_NT1) != 0) {
+ if (ms_fnmatch_protocol(low_mask, low_name, PROTOCOL_NT1) != 0) {
continue;
}
diff --git a/source4/ntvfs/posix/pvfs_dirlist.c b/source4/ntvfs/posix/pvfs_dirlist.c
index 77f19c3585..1bc91c1c78 100644
--- a/source4/ntvfs/posix/pvfs_dirlist.c
+++ b/source4/ntvfs/posix/pvfs_dirlist.c
@@ -199,7 +199,7 @@ const char *pvfs_list_next(struct pvfs_dir *dir, off_t *ofs)
if (*ofs == DIR_OFFSET_DOT) {
(*ofs) = DIR_OFFSET_DOTDOT;
dir->offset = *ofs;
- if (ms_fnmatch(dir->pattern, ".", protocol) == 0) {
+ if (ms_fnmatch_protocol(dir->pattern, ".", protocol) == 0) {
dcache_add(dir, ".");
return ".";
}
@@ -208,7 +208,7 @@ const char *pvfs_list_next(struct pvfs_dir *dir, off_t *ofs)
if (*ofs == DIR_OFFSET_DOTDOT) {
(*ofs) = DIR_OFFSET_BASE;
dir->offset = *ofs;
- if (ms_fnmatch(dir->pattern, "..", protocol) == 0) {
+ if (ms_fnmatch_protocol(dir->pattern, "..", protocol) == 0) {
dcache_add(dir, "..");
return "..";
}
@@ -228,10 +228,10 @@ const char *pvfs_list_next(struct pvfs_dir *dir, off_t *ofs)
continue;
}
- if (ms_fnmatch(dir->pattern, dname, protocol) != 0) {
+ if (ms_fnmatch_protocol(dir->pattern, dname, protocol) != 0) {
char *short_name = pvfs_short_name_component(dir->pvfs, dname);
if (short_name == NULL ||
- ms_fnmatch(dir->pattern, short_name, protocol) != 0) {
+ ms_fnmatch_protocol(dir->pattern, short_name, protocol) != 0) {
talloc_free(short_name);
continue;
}
diff --git a/source4/ntvfs/simple/svfs_util.c b/source4/ntvfs/simple/svfs_util.c
index 75261f7277..c4e015668c 100644
--- a/source4/ntvfs/simple/svfs_util.c
+++ b/source4/ntvfs/simple/svfs_util.c
@@ -101,7 +101,7 @@ struct svfs_dir *svfs_list_unix(TALLOC_CTX *mem_ctx, struct ntvfs_request *req,
if (!low_name) { continue; }
/* check it matches the wildcard pattern */
- if (ms_fnmatch(low_mask, low_name, PROTOCOL_NT1) != 0) {
+ if (ms_fnmatch_protocol(low_mask, low_name, PROTOCOL_NT1) != 0) {
continue;
}
diff --git a/source4/torture/masktest.c b/source4/torture/masktest.c
index 9f156b807b..65c844bc27 100644
--- a/source4/torture/masktest.c
+++ b/source4/torture/masktest.c
@@ -49,7 +49,7 @@ static bool reg_match_one(struct smbcli_state *cli, const char *pattern, const c
if (ISDOTDOT(file)) file = ".";
- return ms_fnmatch(pattern, file, cli->transport->negotiate.protocol)==0;
+ return ms_fnmatch_protocol(pattern, file, cli->transport->negotiate.protocol)==0;
}
static char *reg_test(struct smbcli_state *cli, TALLOC_CTX *mem_ctx, const char *pattern, const char *long_name, const char *short_name)