mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-03-08 20:58:20 +03:00
network/l2tp: parse address or address type from correct string
Fixes a bug introduced by 8b49ee2dcda04f8147650f7d9fb93662caf3ea2e. Fixes #26011. (cherry picked from commit bf4a5ac804d85a1e8df8226e8595219aa6fdafae)
This commit is contained in:
parent
b215afc58d
commit
33e6d13381
@ -522,7 +522,7 @@ int config_parse_l2tp_tunnel_local_address(
|
||||
return log_oom();
|
||||
}
|
||||
|
||||
type = l2tp_local_address_type_from_string(rvalue);
|
||||
type = l2tp_local_address_type_from_string(addr_or_type);
|
||||
if (type >= 0) {
|
||||
free_and_replace(t->local_ifname, ifname);
|
||||
t->local_address_type = type;
|
||||
@ -535,10 +535,10 @@ int config_parse_l2tp_tunnel_local_address(
|
||||
return 0;
|
||||
}
|
||||
|
||||
r = in_addr_from_string_auto(rvalue, &f, &a);
|
||||
r = in_addr_from_string_auto(addr_or_type, &f, &a);
|
||||
if (r < 0) {
|
||||
log_syntax(unit, LOG_WARNING, filename, line, r,
|
||||
"Invalid L2TP Tunnel local address specified, ignoring assignment: %s", rvalue);
|
||||
"Invalid L2TP Tunnel local address \"%s\" specified, ignoring assignment: %s", addr_or_type, rvalue);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user