When freeing the talloc ctx at the end of the routine,
it must be a talloc ctx created inside. talloc_tos() needs
to be valid after the function finishes, since callers
(may) have data attached to it.
Michael
Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
113c5d28edabdd17a2507e68aad612aa21c758f3)
struct registry_value *value;
WERROR wresult;
char *elogname = info->logname;
- TALLOC_CTX *ctx = talloc_tos();
+ TALLOC_CTX *ctx = talloc_stackframe();
bool ret = false;
DEBUG( 4, ( "sync_eventlog_params with %s\n", elogname ) );