diff options
author | Felix Fietkau <nbd@openwrt.org> | 2012-06-18 23:41:17 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2012-06-18 23:41:17 +0200 |
commit | a667ba53a212dd0bd0a09467036c5db9dfe8bfbb (patch) | |
tree | 5437af12b9101e83af968d029369d7f0dd2f5432 | |
parent | e22d6c5ce7b579a3af3a5da7d692aaf952a8f651 (diff) |
add support for using <addr>/<mask> in route/route6 config sections
-rw-r--r-- | interface-ip.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/interface-ip.c b/interface-ip.c index d8d8606..b097c1f 100644 --- a/interface-ip.c +++ b/interface-ip.c @@ -220,7 +220,7 @@ interface_ip_add_route(struct interface *iface, struct blob_attr *attr, bool v6) } if ((cur = tb[ROUTE_TARGET]) != NULL) { - if (!inet_pton(af, blobmsg_data(cur), &route->addr)) { + if (!parse_ip_and_netmask(af, blobmsg_data(cur), &route->addr, &route->mask)) { DPRINTF("Failed to parse route target: %s\n", (char *) blobmsg_data(cur)); goto error; } |