Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
char *domain = NULL;
char *name;
char *p;
+ char *result;
/* This cannot work when the winbind separator = @ */
return NULL;
}
- return talloc_asprintf(ctx, "%s%c%s", domain, sep, name);
+ result = talloc_asprintf(ctx, "%s%c%s", domain, sep, name);
+ wbcFreeMemory(domain);
+ return result;
}
static int _pam_delete_cred(pam_handle_t *pamh, int flags,