s3:vfs/shadow_copy2 fix some compiler warnings
authorChristian Ambach <ambi@samba.org>
Tue, 8 May 2012 07:15:12 +0000 (09:15 +0200)
committerChristian Ambach <ambi@samba.org>
Tue, 8 May 2012 09:15:07 +0000 (11:15 +0200)
about unused variables

Autobuild-User: Christian Ambach <ambi@samba.org>
Autobuild-Date: Tue May  8 11:15:07 CEST 2012 on sn-devel-104

source3/modules/vfs_shadow_copy2.c

index 4efc0cad5722f31c3e37bba95e9bf3ce3e41e125..0e6e14fc72c6f01fe7a7c42a13d403a47a538f5c 100644 (file)
@@ -159,7 +159,7 @@ static char *shadow_copy2_insert_string(TALLOC_CTX *mem_ctx,
                DEBUG(10, ("strftime failed\n"));
                return NULL;
        }
-       return talloc_asprintf(talloc_tos(), "/%s/%s",
+       return talloc_asprintf(mem_ctx, "/%s/%s",
                               lp_parm_const_string(
                                       SNUM(handle->conn), "shadow", "snapdir",
                                       ".snapshots"),
@@ -997,8 +997,7 @@ static char *shadow_copy2_find_snapdir(TALLOC_CTX *mem_ctx,
        return NULL;
 }
 
-static bool shadow_copy2_snapshot_to_gmt(TALLOC_CTX *mem_ctx,
-                                        vfs_handle_struct *handle,
+static bool shadow_copy2_snapshot_to_gmt(vfs_handle_struct *handle,
                                         const char *name,
                                         char *gmt, size_t gmt_len)
 {
@@ -1112,7 +1111,7 @@ static int shadow_copy2_get_shadow_copy_data(
                 * directory
                 */
                if (!shadow_copy2_snapshot_to_gmt(
-                           tmp_ctx, handle, d->d_name,
+                           handle, d->d_name,
                            snapshot, sizeof(snapshot))) {
 
                        DEBUG(6, ("shadow_copy2_get_shadow_copy_data: "