summaryrefslogtreecommitdiff
path: root/src/network/networkd-routing-policy-rule.c
diff options
context:
space:
mode:
authorSusant Sahani <ssahani@vmware.com>2021-01-19 12:58:53 +0100
committerLuca Boccassi <luca.boccassi@gmail.com>2021-01-19 16:37:46 +0000
commitc038ce4606f93d9e58147f87703125270fb744e2 (patch)
tree32afe8a588f31619472bd93c86bddefcacc7677b /src/network/networkd-routing-policy-rule.c
parent656e5aa4520b6d26fd0f04379b7a0ab416563b9e (diff)
downloadsystemd-c038ce4606f93d9e58147f87703125270fb744e2.tar.gz
network: add support to RoutingPolicyRule lookup table name
Diffstat (limited to 'src/network/networkd-routing-policy-rule.c')
-rw-r--r--src/network/networkd-routing-policy-rule.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/network/networkd-routing-policy-rule.c b/src/network/networkd-routing-policy-rule.c
index 6e00e5f9cb..3534232822 100644
--- a/src/network/networkd-routing-policy-rule.c
+++ b/src/network/networkd-routing-policy-rule.c
@@ -8,6 +8,7 @@
#include "conf-parser.h"
#include "fileio.h"
#include "format-util.h"
+#include "hashmap.h"
#include "ip-protocol-list.h"
#include "netlink-util.h"
#include "networkd-manager.h"
@@ -1129,9 +1130,10 @@ int config_parse_routing_policy_rule_table(
if (r < 0)
return log_oom();
- r = safe_atou32(rvalue, &n->table);
+ r = route_table_from_string_full(network->manager, rvalue, &n->table);
if (r < 0) {
- log_syntax(unit, LOG_WARNING, filename, line, r, "Failed to parse RPDB rule table, ignoring: %s", rvalue);
+ log_syntax(unit, LOG_WARNING, filename, line, r,
+ "Could not parse RPDB rule route table number \"%s\", ignoring assignment: %m", rvalue);
return 0;
}