]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: move a DEBUG in unix_convert()
authorRalph Boehme <slow@samba.org>
Sat, 2 May 2020 06:09:24 +0000 (08:09 +0200)
committerJeremy Allison <jra@samba.org>
Tue, 5 May 2020 19:18:42 +0000 (19:18 +0000)
Ensure a successfull conversion via early exit also logs a message.

While at it, use smb_fname_str_dbg() to print the string which ensure any stream
component or twrp value is also printed.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/filename.c

index 6b3e08579abde3e4238c3b1c213a03c907e81954..913f192ab2fa61a426a7dbdc6020a2eb92fa3de2 100644 (file)
@@ -1345,9 +1345,6 @@ NTSTATUS unix_convert(TALLOC_CTX *mem_ctx,
         * The name has been resolved.
         */
 
-       DBG_DEBUG("Conversion finished [%s] -> [%s]\n",
-                  state->orig_path, state->smb_fname->base_name);
-
  done:
        /* Add back the stream if one was stripped off originally. */
        if (state->stream != NULL) {
@@ -1359,6 +1356,10 @@ NTSTATUS unix_convert(TALLOC_CTX *mem_ctx,
                        goto fail;
                }
        }
+
+       DBG_DEBUG("Conversion finished [%s] -> [%s]\n",
+                  state->orig_path, smb_fname_str_dbg(state->smb_fname));
+
        TALLOC_FREE(state->dirpath);
        *smb_fname_out = state->smb_fname;
        return NT_STATUS_OK;