Only called there.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
bool ms_has_wild(const char *s);
bool ms_has_wild_w(const smb_ucs2_t *s);
bool mask_match(const char *string, const char *pattern, bool is_case_sensitive);
-bool mask_match_search(const char *string, const char *pattern, bool is_case_sensitive);
bool mask_match_list(const char *string, char **list, int listLen, bool is_case_sensitive);
#include "lib/util/unix_match.h"
bool name_to_fqdn(fstring fqdn, const char *name);
return ms_fnmatch_protocol(pattern, string, Protocol, is_case_sensitive) == 0;
}
-/*******************************************************************
- A wrapper that handles case sensitivity and the special handling
- of the ".." name. Variant that is only called by old search code which requires
- pattern translation.
-*******************************************************************/
-
-bool mask_match_search(const char *string, const char *pattern, bool is_case_sensitive)
-{
- if (ISDOTDOT(string))
- string = ".";
- if (ISDOT(pattern))
- return False;
-
- return ms_fnmatch(pattern, string, True, is_case_sensitive) == 0;
-}
-
/*******************************************************************
A wrapper that handles a list of patterns and calls mask_match()
on each. Returns True if any of the patterns match.
DEBUG(8,("put name [%s] from [%s] into dir struct\n",buf+30, fname));
}
+/*******************************************************************
+ A wrapper that handles case sensitivity and the special handling
+ of the ".." name.
+*******************************************************************/
+
+static bool mask_match_search(const char *string,
+ const char *pattern,
+ bool is_case_sensitive)
+{
+ if (ISDOTDOT(string)) {
+ string = ".";
+ }
+ if (ISDOT(pattern)) {
+ return False;
+ }
+
+ return ms_fnmatch(pattern, string, True, is_case_sensitive) == 0;
+}
+
static bool mangle_mask_match(connection_struct *conn,
const char *filename,
const char *mask)