mirror of
https://github.com/samba-team/samba.git
synced 2025-02-26 21:57:41 +03:00
lib: Slightly simplify add_interface()
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
280e9191cb
commit
313d207d72
@ -94,7 +94,11 @@ static void add_interface(TALLOC_CTX *mem_ctx, const struct iface_struct *ifs, s
|
||||
return;
|
||||
}
|
||||
|
||||
iface = talloc(*interfaces == NULL ? mem_ctx : *interfaces, struct interface);
|
||||
if (*interfaces != NULL) {
|
||||
mem_ctx = *interfaces;
|
||||
}
|
||||
|
||||
iface = talloc(mem_ctx, struct interface);
|
||||
if (iface == NULL)
|
||||
return;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user