diff options
Diffstat (limited to 'src/network')
-rw-r--r-- | src/network/netdev/vxlan.c | 4 | ||||
-rw-r--r-- | src/network/networkd-network-gperf.gperf | 2 | ||||
-rw-r--r-- | src/network/networkd-network.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/network/netdev/vxlan.c b/src/network/netdev/vxlan.c index 10c892b044..231f5cb442 100644 --- a/src/network/netdev/vxlan.c +++ b/src/network/netdev/vxlan.c @@ -252,8 +252,8 @@ int config_parse_destination_port(const char *unit, assert(rvalue); assert(data); - r = safe_atou16(rvalue, &port); - if (r < 0 || port <= 0) { + r = parse_ip_port(rvalue, &port); + if (r < 0) { log_syntax(unit, LOG_ERR, filename, line, r, "Failed to parse VXLAN destination port '%s'.", rvalue); return 0; } diff --git a/src/network/networkd-network-gperf.gperf b/src/network/networkd-network-gperf.gperf index 0a5cd763dd..c9b9044a14 100644 --- a/src/network/networkd-network-gperf.gperf +++ b/src/network/networkd-network-gperf.gperf @@ -101,7 +101,7 @@ DHCP.RouteMetric, config_parse_unsigned, DHCP.RouteTable, config_parse_dhcp_route_table, 0, offsetof(Network, dhcp_route_table) DHCP.UseTimezone, config_parse_bool, 0, offsetof(Network, dhcp_use_timezone) DHCP.IAID, config_parse_iaid, 0, offsetof(Network, iaid) -DHCP.ListenPort, config_parse_uint32, 0, offsetof(Network, dhcp_client_port) +DHCP.ListenPort, config_parse_uint16, 0, offsetof(Network, dhcp_client_port) IPv6AcceptRA.UseDNS, config_parse_bool, 0, offsetof(Network, ipv6_accept_ra_use_dns) IPv6AcceptRA.UseDomains, config_parse_dhcp_use_domains, 0, offsetof(Network, ipv6_accept_ra_use_domains) IPv6AcceptRA.RouteTable, config_parse_dhcp_route_table, 0, offsetof(Network, ipv6_accept_ra_route_table) diff --git a/src/network/networkd-network.h b/src/network/networkd-network.h index e05dccda29..d13e306add 100644 --- a/src/network/networkd-network.h +++ b/src/network/networkd-network.h @@ -114,7 +114,7 @@ struct Network { char *dhcp_hostname; unsigned dhcp_route_metric; uint32_t dhcp_route_table; - uint32_t dhcp_client_port; + uint16_t dhcp_client_port; bool dhcp_send_hostname; bool dhcp_broadcast; bool dhcp_critical; |