vfs: Convert shadow_copy2_unlink to cp_smb_filename
authorVolker Lendecke <vl@samba.org>
Thu, 11 Apr 2013 13:32:39 +0000 (15:32 +0200)
committerJeremy Allison <jra@samba.org>
Wed, 17 Apr 2013 21:49:55 +0000 (14:49 -0700)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/modules/vfs_shadow_copy2.c

index 1cf8e37ba4ab188b84fad8c37514e89421543847..03b2e07508fbbeeca067e9bd4916dfa2196af56e 100644 (file)
@@ -710,7 +710,6 @@ static int shadow_copy2_unlink(vfs_handle_struct *handle,
        char *stripped;
        int ret, saved_errno;
        struct smb_filename *conv;
-       NTSTATUS status;
 
        if (!shadow_copy2_strip_snapshot(talloc_tos(), handle,
                                         smb_fname->base_name,
@@ -720,8 +719,8 @@ static int shadow_copy2_unlink(vfs_handle_struct *handle,
        if (timestamp == 0) {
                return SMB_VFS_NEXT_UNLINK(handle, smb_fname);
        }
-       status = copy_smb_filename(talloc_tos(), smb_fname, &conv);
-       if (!NT_STATUS_IS_OK(status)) {
+       conv = cp_smb_filename(talloc_tos(), smb_fname);
+       if (conv == NULL) {
                errno = ENOMEM;
                return -1;
        }