summaryrefslogtreecommitdiff
path: root/source3/utils/profiles.c
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2010-05-24 15:08:58 +0200
committerMichael Adam <obnox@samba.org>2010-05-25 10:35:30 +0200
commitbf65ff5ea2b84f3f5406d840f759da87e146cc3a (patch)
treea5dc24d632ba52807ab1e6ed4d1037d3d1548cca /source3/utils/profiles.c
parent7b2f5f20daded43705f4321acf1b9311fa0fe6d4 (diff)
downloadsamba-bf65ff5ea2b84f3f5406d840f759da87e146cc3a.tar.gz
samba-bf65ff5ea2b84f3f5406d840f759da87e146cc3a.tar.bz2
samba-bf65ff5ea2b84f3f5406d840f759da87e146cc3a.zip
s3:profiles: use regval_ctr_init() instead of direct allocation
Diffstat (limited to 'source3/utils/profiles.c')
-rw-r--r--source3/utils/profiles.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/utils/profiles.c b/source3/utils/profiles.c
index 5e2cd9a392..f793704be5 100644
--- a/source3/utils/profiles.c
+++ b/source3/utils/profiles.c
@@ -140,7 +140,8 @@ static bool copy_registry_tree( REGF_FILE *infile, REGF_NK_REC *nk,
return False;
}
- if ( !(values = TALLOC_ZERO_P( subkeys, struct regval_ctr )) ) {
+ werr = regval_ctr_init(subkeys, &values);
+ if (!W_ERROR_IS_OK(werr)) {
TALLOC_FREE( subkeys );
DEBUG(0,("copy_registry_tree: talloc() failure!\n"));
return False;