s3:utils: avoid cli_nt_error()/cli_errstr() if we already have the status
authorStefan Metzmacher <metze@samba.org>
Thu, 7 Jul 2011 13:33:43 +0000 (15:33 +0200)
committerStefan Metzmacher <metze@samba.org>
Thu, 7 Jul 2011 13:37:29 +0000 (15:37 +0200)
metze

source3/utils/net_rpc.c

index 5c21b637410ae7571d2aa27dcc2aedb9a4bf4c4e..5952f4fe32b14228b5a3d846a263c1741c440395 100644 (file)
@@ -3833,8 +3833,8 @@ static NTSTATUS sync_files(struct copy_clistate *cp_clistate, const char *mask)
        if (!NT_STATUS_IS_OK(status)) {
                d_fprintf(stderr, _("cli_resolve_path %s failed with error: "
                                    "%s\n"),
-                       mask, cli_errstr(cp_clistate->cli_share_src));
-               return cli_nt_error(cp_clistate->cli_share_src);
+                       mask, nt_errstr(status));
+               return status;
        }
 
        status = cli_list(targetcli, targetpath, cp_clistate->attribute,