projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ca6038b
)
networkd: route - ignore unknown address family
author
Tom Gundersen
<teg@jklm.no>
Mon, 8 Dec 2014 12:58:48 +0000
(13:58 +0100)
committer
Tom Gundersen
<teg@jklm.no>
Mon, 8 Dec 2014 17:38:55 +0000
(18:38 +0100)
src/network/networkd-route.c
patch
|
blob
|
history
diff --git
a/src/network/networkd-route.c
b/src/network/networkd-route.c
index
4e389db
..
590dd49
100644
(file)
--- a/
src/network/networkd-route.c
+++ b/
src/network/networkd-route.c
@@
-353,6
+353,12
@@
int config_parse_destination(const char *unit,
return 0;
}
+ if (f != AF_INET && f != AF_INET6) {
+ log_syntax(unit, LOG_ERR, filename, line, EINVAL,
+ "Unknown address family, ignoring assignment: %s", address);
+ return 0;
+ }
+
/* prefixlen */
if (e) {
r = safe_atou8(e + 1, &prefixlen);
@@
-362,7
+368,7
@@
int config_parse_destination(const char *unit,
return 0;
}
} else {
- switch (
n->family
) {
+ switch (
f
) {
case AF_INET:
prefixlen = 32;
break;