From a67a553f40833a182b89a058d59015bcf19640f0 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Mon, 20 Sep 2010 00:40:44 +0200 Subject: s3:services_db: untangle assignments from check in construct_service_sd(). --- source3/services/services_db.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'source3/services') diff --git a/source3/services/services_db.c b/source3/services/services_db.c index 0afc6c16b4..f3c550a91f 100644 --- a/source3/services/services_db.c +++ b/source3/services/services_db.c @@ -114,13 +114,17 @@ static struct security_descriptor* construct_service_sd( TALLOC_CTX *ctx ) /* create the security descriptor */ - if ( !(theacl = make_sec_acl(ctx, NT4_ACL_REVISION, i, ace)) ) + theacl = make_sec_acl(ctx, NT4_ACL_REVISION, i, ace); + if (theacl == NULL) { return NULL; + } - if ( !(sd = make_sec_desc(ctx, SECURITY_DESCRIPTOR_REVISION_1, - SEC_DESC_SELF_RELATIVE, NULL, NULL, NULL, - theacl, &sd_size)) ) + sd = make_sec_desc(ctx, SECURITY_DESCRIPTOR_REVISION_1, + SEC_DESC_SELF_RELATIVE, NULL, NULL, NULL, + theacl, &sd_size); + if (sd == NULL) { return NULL; + } return sd; } -- cgit