diff options
author | Kjetil Torgrim Homme <kjetil.homme@redpill-linpro.com> | 2021-09-07 11:34:44 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-07 11:34:44 +0200 |
commit | e533ddf6cf4e454dc1cd9a62b7d6ac066f1cc2af (patch) | |
tree | f4bf95b63ed16f8cb9a538bf93c3899eb776ed05 /src | |
parent | c6613b5e48a6fd40f871fdd60f00a681339a588e (diff) |
clarify requirements for a link local route (#226)
This gives a better hint on how to add a link local route. Ie., if the user tries to add a local route (without a gateway (via)), they will get an error message that a global route needs via, and hopefully understand they should use scope: local. Also, the docs spell this out.
COMMITS:
* clarify requirements for a link local route
* Update doc/netplan.md
Co-authored-by: Simon Chopin <87005181+schopin-pro@users.noreply.github.com>
Co-authored-by: Simon Chopin <87005181+schopin-pro@users.noreply.github.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/parse.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/parse.c b/src/parse.c index 09cd1e2..96cdb59 100644 --- a/src/parse.c +++ b/src/parse.c @@ -1669,7 +1669,7 @@ handle_routes(yaml_document_t* doc, yaml_node_t* node, const void* _, GError** e } else if ( g_ascii_strcasecmp(cur_route->type, "unicast") == 0 && g_ascii_strcasecmp(cur_route->scope, "global") == 0 && (!cur_route->to || !cur_route->via)) { - yaml_error(node, error, "unicast route must include both a 'to' and 'via' IP"); + yaml_error(node, error, "global unicast route must include both a 'to' and 'via' IP"); goto err; } else if (g_ascii_strcasecmp(cur_route->type, "unicast") != 0 && !cur_route->to) { yaml_error(node, error, "non-unicast routes must specify a 'to' IP"); |