diff options
| author | David Lamparter <equinox@opensourcerouting.org> | 2017-06-15 16:22:42 +0200 |
|---|---|---|
| committer | David Lamparter <equinox@opensourcerouting.org> | 2017-06-15 16:22:42 +0200 |
| commit | f43cd318b26a3dc57a0e6f40bcccdd5ce1886432 (patch) | |
| tree | eed2449282c488b77e1dc45b0e10c7d2ab34c45b /zebra/client_main.c | |
| parent | ffef22509f2a0aafcfecd56f00d75917e9139dc5 (diff) | |
| parent | 68fc8f1f26e44aaaac9b39421519863e5b18bc7a (diff) | |
Merge pull request #711 ("Coverity munging")
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'zebra/client_main.c')
| -rw-r--r-- | zebra/client_main.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/zebra/client_main.c b/zebra/client_main.c index c9d738bb08..0e77ea4aec 100644 --- a/zebra/client_main.c +++ b/zebra/client_main.c @@ -48,7 +48,12 @@ zebra_test_ipv4 (int command, int type, char *prefix, char *gateway, struct in_addr *gpnt; str2prefix_ipv4 (prefix, &p); - inet_aton (gateway, &gate); + if (!inet_aton (gateway, &gate)) + { + printf("Gateway specified: %s is illegal\n", gateway); + return; + } + gpnt = &gate; api.vrf_id = VRF_DEFAULT; |
