]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: Use file_id_str_buf() in scavenger_timer()
authorVolker Lendecke <vl@samba.org>
Sat, 9 Nov 2019 17:30:37 +0000 (18:30 +0100)
committerJeremy Allison <jra@samba.org>
Tue, 12 Nov 2019 20:56:34 +0000 (20:56 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/scavenger.c

index bed384b865e21f5ffd1367702d4d3642444ec552..a7c210f664da83762215862e813ec72074cdfcda 100644 (file)
@@ -467,28 +467,30 @@ static void scavenger_timer(struct tevent_context *ev,
 {
        struct scavenger_timer_context *ctx =
                talloc_get_type_abort(data, struct scavenger_timer_context);
+       struct file_id_buf idbuf;
        NTSTATUS status;
        bool ok;
 
-       DEBUG(10, ("scavenger: do cleanup for file %s at %s\n",
-                 file_id_string_tos(&ctx->msg.file_id),
-                 timeval_string(talloc_tos(), &t, true)));
+       DBG_DEBUG("do cleanup for file %s at %s\n",
+                 file_id_str_buf(ctx->msg.file_id, &idbuf),
+                 timeval_string(talloc_tos(), &t, true));
 
        ok = share_mode_cleanup_disconnected(ctx->msg.file_id,
                                             ctx->msg.open_persistent_id);
        if (!ok) {
-               DEBUG(2, ("Failed to cleanup share modes and byte range locks "
-                         "for file %s open %llu\n",
-                         file_id_string_tos(&ctx->msg.file_id),
-                         (unsigned long long)ctx->msg.open_persistent_id));
+               DBG_WARNING("Failed to cleanup share modes and byte range "
+                           "locks for file %s open %"PRIu64"\n",
+                           file_id_str_buf(ctx->msg.file_id, &idbuf),
+                           ctx->msg.open_persistent_id);
        }
 
        status = smbXsrv_open_cleanup(ctx->msg.open_persistent_id);
        if (!NT_STATUS_IS_OK(status)) {
-               DEBUG(2, ("Failed to cleanup open global for file %s open %llu:"
-                         " %s\n", file_id_string_tos(&ctx->msg.file_id),
-                         (unsigned long long)ctx->msg.open_persistent_id,
-                         nt_errstr(status)));
+               DBG_WARNING("Failed to cleanup open global for file %s open "
+                           "%"PRIu64": %s\n",
+                           file_id_str_buf(ctx->msg.file_id, &idbuf),
+                           ctx->msg.open_persistent_id,
+                           nt_errstr(status));
        }
 }