commit 902b01679fcdf20b90452ab7321af8e3b197c80f
parent bab33b837dea821e5bbc662b32e16332d38a5f87
Author: Christophe Coustet <christophe.coustet@meso-star.com>
Date: Fri, 4 Nov 2016 15:46:49 +0100
Fix double init in test.
Diffstat:
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/src/test_sanim_utils.c b/src/test_sanim_utils.c
@@ -187,7 +187,7 @@ my_type_recursive_copy_
res = my_type_recursive_copy_(alloc, child, tmp, &node);
if (res != RES_OK) goto error;
my_type_add_child(root, node);
- my_type_ref_put(node); /* node has is referenced by root */
+ my_type_ref_put(node); /* node is referenced by root */
}
exit:
*dst = root;
@@ -213,9 +213,6 @@ my_type_recursive_copy
darray_tmp_init(alloc, &tmp);
res = my_type_recursive_copy_(alloc, src, &tmp, dst);
if (res != RES_OK) goto error;
- (*dst)->my_data = 0;
- (*dst)->allocator = alloc;
- ref_init(&(*dst)->ref);
exit:
darray_tmp_release(&tmp);
return res;