git.samba.org
/
sfrench
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
56a5d05
)
r22591: Fix up the examples also.
author
Jeremy Allison
<jra@samba.org>
Mon, 30 Apr 2007 03:38:19 +0000
(
03:38
+0000)
committer
Gerald (Jerry) Carter
<jerry@samba.org>
Wed, 10 Oct 2007 17:19:49 +0000
(12:19 -0500)
Jeremy.
(This used to be commit
aa5a1591c626e2828244a78f237af8a59af57784
)
examples/VFS/shadow_copy_test.c
patch
|
blob
|
history
diff --git
a/examples/VFS/shadow_copy_test.c
b/examples/VFS/shadow_copy_test.c
index 155181229b190900532ce16c197d446fc5fc2acb..98ac304ee2c74138e7ed1304d3121649da268d5d 100644
(file)
--- a/
examples/VFS/shadow_copy_test.c
+++ b/
examples/VFS/shadow_copy_test.c
@@
-58,7
+58,11
@@
static int test_get_shadow_copy_data(vfs_handle_struct *handle, files_struct *fs
shadow_copy_data->num_volumes = num;
if (labels) {
- shadow_copy_data->labels = TALLOC_ZERO_ARRAY(shadow_copy_data->mem_ctx,SHADOW_COPY_LABEL,num);
+ if (num) {
+ shadow_copy_data->labels = TALLOC_ZERO_ARRAY(shadow_copy_data->mem_ctx,SHADOW_COPY_LABEL,num);
+ } else {
+ shadow_copy_data->labels = NULL;
+ }
for (i=0;i<num;i++) {
snprintf(shadow_copy_data->labels[i], sizeof(SHADOW_COPY_LABEL), "@GMT-2003.08.05-12.%02u.00",i);
}