From 698f54456f52e7854a512e5355c54168662d2ccb Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Thu, 29 Oct 2015 09:26:10 +0100 Subject: [PATCH] platform: correct the type for route.pref_src It's an IPv4 address. --- src/platform/nm-fake-platform.c | 2 +- src/platform/nm-linux-platform.c | 2 +- src/platform/nm-platform.c | 2 +- src/platform/nm-platform.h | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/platform/nm-fake-platform.c b/src/platform/nm-fake-platform.c index b4f855eeef..cbb9775714 100644 --- a/src/platform/nm-fake-platform.c +++ b/src/platform/nm-fake-platform.c @@ -1189,7 +1189,7 @@ ip6_route_delete (NMPlatform *platform, int ifindex, struct in6_addr network, in static gboolean ip4_route_add (NMPlatform *platform, int ifindex, NMIPConfigSource source, in_addr_t network, int plen, in_addr_t gateway, - guint32 pref_src, guint32 metric, guint32 mss) + in_addr_t pref_src, guint32 metric, guint32 mss) { NMFakePlatformPrivate *priv = NM_FAKE_PLATFORM_GET_PRIVATE (platform); NMPlatformIP4Route route; diff --git a/src/platform/nm-linux-platform.c b/src/platform/nm-linux-platform.c index 29ffd6e6ab..ed8918be61 100644 --- a/src/platform/nm-linux-platform.c +++ b/src/platform/nm-linux-platform.c @@ -4474,7 +4474,7 @@ _nmp_vt_cmd_plobj_to_nl_ip6_route (NMPlatform *platform, const NMPlatformObject static gboolean ip4_route_add (NMPlatform *platform, int ifindex, NMIPConfigSource source, in_addr_t network, int plen, in_addr_t gateway, - guint32 pref_src, guint32 metric, guint32 mss) + in_addr_t pref_src, guint32 metric, guint32 mss) { NMPObject obj_needle; auto_nl_object struct nl_object *nlo = NULL; diff --git a/src/platform/nm-platform.c b/src/platform/nm-platform.c index 565cf42bb7..f28a544f87 100644 --- a/src/platform/nm-platform.c +++ b/src/platform/nm-platform.c @@ -2216,7 +2216,7 @@ gboolean nm_platform_ip4_route_add (NMPlatform *self, int ifindex, NMIPConfigSource source, in_addr_t network, int plen, - in_addr_t gateway, guint32 pref_src, + in_addr_t gateway, in_addr_t pref_src, guint32 metric, guint32 mss) { _CHECK_SELF (self, klass, FALSE); diff --git a/src/platform/nm-platform.h b/src/platform/nm-platform.h index e894504028..f7c44d4eb6 100644 --- a/src/platform/nm-platform.h +++ b/src/platform/nm-platform.h @@ -287,7 +287,7 @@ struct _NMPlatformIP4Route { /* RTA_PREFSRC/rtnl_route_get_pref_src(). A value of zero means that * no pref-src is set. */ - guint32 pref_src; + in_addr_t pref_src; }; struct _NMPlatformIP6Route { @@ -534,7 +534,7 @@ typedef struct { GArray * (*ip6_route_get_all) (NMPlatform *, int ifindex, NMPlatformGetRouteFlags flags); gboolean (*ip4_route_add) (NMPlatform *, int ifindex, NMIPConfigSource source, in_addr_t network, int plen, in_addr_t gateway, - guint32 pref_src, guint32 metric, guint32 mss); + in_addr_t pref_src, guint32 metric, guint32 mss); gboolean (*ip6_route_add) (NMPlatform *, int ifindex, NMIPConfigSource source, struct in6_addr network, int plen, struct in6_addr gateway, guint32 metric, guint32 mss); @@ -738,7 +738,7 @@ GArray *nm_platform_ip4_route_get_all (NMPlatform *self, int ifindex, NMPlatform GArray *nm_platform_ip6_route_get_all (NMPlatform *self, int ifindex, NMPlatformGetRouteFlags flags); gboolean nm_platform_ip4_route_add (NMPlatform *self, int ifindex, NMIPConfigSource source, in_addr_t network, int plen, in_addr_t gateway, - guint32 pref_src, guint32 metric, guint32 mss); + in_addr_t pref_src, guint32 metric, guint32 mss); gboolean nm_platform_ip6_route_add (NMPlatform *self, int ifindex, NMIPConfigSource source, struct in6_addr network, int plen, struct in6_addr gateway, guint32 metric, guint32 mss);