mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
loadparm: use lp_printername ctx param instead of tos
lp_printername() takes a TALLOC_CTX argument, but proceeds to use talloc_tos() in a subsequent lp__printername call. Fix it to use the parameter - most callers use talloc_tos() as the argument, the others have a temporary context around. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
This commit is contained in:
parent
de42413365
commit
a299de85ab
@ -5274,7 +5274,7 @@ void lp_copy_service(int snum, const char *new_name)
|
||||
|
||||
const char *lp_printername(TALLOC_CTX *ctx, int snum)
|
||||
{
|
||||
const char *ret = lp__printername(talloc_tos(), snum);
|
||||
const char *ret = lp__printername(ctx, snum);
|
||||
if (ret == NULL || *ret == '\0') {
|
||||
ret = lp_const_servicename(snum);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user