• Dan Williams's avatar
    core: fix erroneous IPv6 routes by making route addition typesafe · ae34fa90
    Dan Williams authored
    Add two helper functions, one for IPv4 and one for IPv6, to ensure
    that the core code benefits from compiler type checking when adding
    routes.  Previously nm_netlink_route_add() took a void* which meant
    we messed up adding IPv6 routes sometimes due to confusion over
    what was supposed to be passed to it.  Also fixes what appears to
    be a C&P error with add_ip6_route_to_gateway().
    Reported by Tomáš Trnka <tomastrnka@gmx.com>
nm-netlink-utils.h 3.27 KB