1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-26 21:57:41 +03:00

smbd: Enhance debugging in set_file_size

I've stumbled over a case where VFS_FTRUNCATE wasn't called due to an
unchanged size. Make that easier to detect. Also, get rid of an ancient
cast to (double).

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
Volker Lendecke 2018-08-07 15:09:04 +02:00 committed by Jeremy Allison
parent 6ca5ba5272
commit 29eb2fc67c

View File

@ -6355,7 +6355,9 @@ static NTSTATUS smb_set_file_size(connection_struct *conn,
return NT_STATUS_OBJECT_NAME_NOT_FOUND;
}
DEBUG(6,("smb_set_file_size: size: %.0f ", (double)size));
DBG_INFO("size: %"PRIu64", file_size_stat=%"PRIu64"\n",
(uint64_t)size,
get_file_size_stat(psbuf));
if (size == get_file_size_stat(psbuf)) {
return NT_STATUS_OK;