lib/util Use lib/util/ms_fnmatch.c in common for gen_fnmatch()
authorAndrew Bartlett <abartlet@samba.org>
Wed, 4 May 2011 10:57:12 +0000 (20:57 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Fri, 6 May 2011 05:51:24 +0000 (07:51 +0200)
gen_fnmatch was a duplicate symbol in the top level build.

gen_fnmatch() used for simple non-CIFS pattern matching, so selecting
the lib/util implementation should not be a concern.

Andrew Bartlett

lib/util/wscript_build
source3/Makefile.in
source3/include/proto.h
source3/lib/ms_fnmatch.c

index 59a2782b6096ab54384bb1b212229013e966a37c..fc5f4b5455c74893ac03b8900398aa4f7e923b5d 100755 (executable)
@@ -5,11 +5,11 @@ common_util_sources = '''talloc_stack.c smb_threads.c xfile.c data_blob.c
                     genrand.c fsusage.c blocking.c become_daemon.c
                     signal.c system.c params.c util.c util_id.c util_net.c
                     util_strlist.c idtree.c debug.c fault.c base64.c
-                    util_str.c util_str_common.c substitute.c'''
+                    util_str.c util_str_common.c substitute.c ms_fnmatch.c'''
 
 common_util_headers = 'debug.h'
 common_util_public_deps = 'talloc pthread LIBCRYPTO'
-s4_util_sources = '''dprintf.c ms_fnmatch.c parmlist.c'''
+s4_util_sources = '''dprintf.c parmlist.c'''
 s4_util_deps = 'DYNCONFIG'
 s4_util_public_deps = 'talloc CHARSET execinfo uid_wrapper'
 s4_util_public_headers = 'attr.h byteorder.h data_blob.h memory.h safe_string.h time.h talloc_stack.h xfile.h dlinklist.h util.h string_wrappers.h'
index 475805f793aae403034f4bcd515f9ab972f9efff..9dfeb7f4333daf98f9b2653fe39d1d3f83033462 100644 (file)
@@ -465,7 +465,7 @@ LIB_OBJ = $(LIBSAMBAUTIL_OBJ) $(UTIL_OBJ) $(CRYPTO_OBJ) \
          lib/util.o lib/util_cmdline.o lib/util_names.o \
          lib/util_sock.o lib/sock_exec.o lib/util_sec.o \
          lib/substitute.o ../lib/util/substitute.o lib/dbwrap_util.o \
-         lib/ms_fnmatch.o lib/errmap_unix.o \
+         lib/ms_fnmatch.o ../lib/util/ms_fnmatch.o lib/errmap_unix.o \
          lib/tallocmsg.o lib/dmallocmsg.o \
          libsmb/clisigning.o libsmb/smb_signing.o \
          ../lib/util/charset/iconv.o intl/lang_tdb.o \
index a6e9cf9b5db0bff4e5b9a3f830a6a6d0b4c7aa3c..6be464381857bb117d8735f9122f3b2e81312221 100644 (file)
@@ -217,7 +217,6 @@ void init_modules(void);
 
 int ms_fnmatch(const char *pattern, const char *string, bool translate_pattern,
               bool is_case_sensitive);
-int gen_fnmatch(const char *pattern, const char *string);
 
 /* The following definitions come from lib/pidfile.c  */
 
index 31c66953a961295706fb0f03b945ec1cc3af420e..272355b7d203d707c2aa943eba6c85480408fb86 100644 (file)
@@ -229,10 +229,3 @@ int ms_fnmatch(const char *pattern, const char *string, bool translate_pattern,
        TALLOC_FREE(s);
        return ret;
 }
-
-
-/* a generic fnmatch function - uses for non-CIFS pattern matching */
-int gen_fnmatch(const char *pattern, const char *string)
-{
-       return ms_fnmatch(pattern, string, true, False);
-}