]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
libsmb: Remove a call to SMBC_errno()
authorVolker Lendecke <vl@samba.org>
Sat, 23 Sep 2023 00:55:55 +0000 (17:55 -0700)
committerJeremy Allison <jra@samba.org>
Mon, 25 Sep 2023 19:01:34 +0000 (19:01 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/libsmb/libsmb_dir.c

index bf7b8f8b9b51db9f9ccf9574e346f6a2816d1864..34d6731b4219609602f0badb248f08b1f1621333 100644 (file)
@@ -2452,9 +2452,9 @@ SMBC_rename_ctx(SMBCCTX *ocontext,
                return -1;
        }
 
-       if (!NT_STATUS_IS_OK(
-               cli_rename(targetcli1, targetpath1, targetpath2, false))) {
-               int eno = SMBC_errno(ocontext, targetcli1);
+       status = cli_rename(targetcli1, targetpath1, targetpath2, false);
+       if (!NT_STATUS_IS_OK(status)) {
+               int eno = cli_status_to_errno(status);
 
                if (eno != EEXIST ||
                    !NT_STATUS_IS_OK(cli_unlink(targetcli1, targetpath2,