smbd: make get_real_filename_full_scan() public
authorRalph Boehme <slow@samba.org>
Thu, 23 Apr 2020 14:09:16 +0000 (16:09 +0200)
committerKarolin Seeger <kseeger@samba.org>
Wed, 13 May 2020 13:31:25 +0000 (13:31 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14350

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(backported from commit aa5f19ddf1dec1ac4386441929bca94727f30ee6)
[Conflicts: source3/smbd/proto.h: more functions are missing in 4.12]

source3/smbd/filename.c
source3/smbd/proto.h

index 5a3b8cc2ebf34b30642a83b3cba2e0576bd51d8d..0695198e286112c0ea7b833a6eaa3b1b1f07ab9d 100644 (file)
@@ -1449,10 +1449,12 @@ static bool sname_equal(const char *name1, const char *name2,
  If the name looks like a mangled name then try via the mangling functions
 ****************************************************************************/
 
-static int get_real_filename_full_scan(connection_struct *conn,
-                                      const char *path, const char *name,
-                                      bool mangled,
-                                      TALLOC_CTX *mem_ctx, char **found_name)
+int get_real_filename_full_scan(connection_struct *conn,
+                               const char *path,
+                               const char *name,
+                               bool mangled,
+                               TALLOC_CTX *mem_ctx,
+                               char **found_name)
 {
        struct smb_Dir *cur_dir;
        const char *dname = NULL;
index 10ffaf6e480922e78cb0c88694960243a660f56f..6e2509e7c574b4691cd53278223576ed17320f12 100644 (file)
@@ -357,6 +357,12 @@ NTSTATUS check_name(connection_struct *conn,
 int get_real_filename(connection_struct *conn, const char *path,
                      const char *name, TALLOC_CTX *mem_ctx,
                      char **found_name);
+int get_real_filename_full_scan(connection_struct *conn,
+                               const char *path,
+                               const char *name,
+                               bool mangled,
+                               TALLOC_CTX *mem_ctx,
+                               char **found_name);
 NTSTATUS filename_convert(TALLOC_CTX *mem_ctx,
                        connection_struct *conn,
                        const char *name_in,