diff options
author | Susant Sahani <ssahani@users.noreply.github.com> | 2017-06-06 16:02:31 +0000 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2017-06-06 12:02:31 -0400 |
commit | 14d20d2bfb221e411c42528546cb9f1bbcb2e879 (patch) | |
tree | 6c95adf070f7a6376364c3aa6b0939fd4557d0e2 /src/network | |
parent | 94fcd9d3a09b86ee035bf0d7400ff81d4fa5d1b5 (diff) | |
download | systemd-14d20d2bfb221e411c42528546cb9f1bbcb2e879.tar.gz systemd-14d20d2bfb221e411c42528546cb9f1bbcb2e879.tar.bz2 systemd-14d20d2bfb221e411c42528546cb9f1bbcb2e879.zip |
networkd: fix route table from unsigned char to uint32_t (#6083)
[zj: struct Route is defined with uint32_t route, so this makes the type of the function
parameter match the field it is assigned to.]
Diffstat (limited to 'src/network')
-rw-r--r-- | src/network/networkd-route.c | 8 | ||||
-rw-r--r-- | src/network/networkd-route.h | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/network/networkd-route.c b/src/network/networkd-route.c index 9535016af7..e5d61ce8cc 100644 --- a/src/network/networkd-route.c +++ b/src/network/networkd-route.c @@ -230,7 +230,7 @@ int route_get(Link *link, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, - unsigned char table, + uint32_t table, Route **ret) { Route route, *existing; @@ -272,7 +272,7 @@ static int route_add_internal( unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, - unsigned char table, + uint32_t table, Route **ret) { _cleanup_route_free_ Route *route = NULL; @@ -318,7 +318,7 @@ int route_add_foreign( unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, - unsigned char table, + uint32_t table, Route **ret) { return route_add_internal(link, &link->routes_foreign, family, dst, dst_prefixlen, tos, priority, table, ret); @@ -331,7 +331,7 @@ int route_add( unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, - unsigned char table, + uint32_t table, Route **ret) { Route *route; diff --git a/src/network/networkd-route.h b/src/network/networkd-route.h index efd1e53d2a..3f389489da 100644 --- a/src/network/networkd-route.h +++ b/src/network/networkd-route.h @@ -59,9 +59,9 @@ void route_free(Route *route); int route_configure(Route *route, Link *link, sd_netlink_message_handler_t callback); int route_remove(Route *route, Link *link, sd_netlink_message_handler_t callback); -int route_get(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, unsigned char table, Route **ret); -int route_add(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, unsigned char table, Route **ret); -int route_add_foreign(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, unsigned char table, Route **ret); +int route_get(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, uint32_t table, Route **ret); +int route_add(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, uint32_t table, Route **ret); +int route_add_foreign(Link *link, int family, const union in_addr_union *dst, unsigned char dst_prefixlen, unsigned char tos, uint32_t priority, uint32_t table, Route **ret); int route_update(Route *route, const union in_addr_union *src, unsigned char src_prefixlen, const union in_addr_union *gw, const union in_addr_union *prefsrc, unsigned char scope, unsigned char protocol); int route_expire_handler(sd_event_source *s, uint64_t usec, void *userdata); |