mirror of
https://github.com/samba-team/samba.git
synced 2025-01-12 09:18:10 +03:00
Do not leak memory in libnet_smbconf_setparm().
Michael
This commit is contained in:
parent
45e3e2451a
commit
a657b1c9f1
@ -258,10 +258,14 @@ WERROR libnet_smbconf_setparm(TALLOC_CTX *mem_ctx,
|
||||
werr = libnet_smbconf_open_path(mem_ctx, service, REG_KEY_WRITE,
|
||||
&key);
|
||||
}
|
||||
W_ERROR_NOT_OK_RETURN(werr);
|
||||
if (!W_ERROR_IS_OK(werr)) {
|
||||
goto done;
|
||||
}
|
||||
|
||||
werr = libnet_smbconf_reg_setvalue_internal(key, param, valstr);
|
||||
|
||||
done:
|
||||
TALLOC_FREE(key);
|
||||
return werr;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user