From 4c0623a080c77ed54fa9fec47c2ab982385cb9a9 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sun, 24 Aug 2014 03:30:01 +0200 Subject: Exit if invalid peers are configured on the command line --- src/options.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/options.c b/src/options.c index 1e7764d..8593da2 100644 --- a/src/options.c +++ b/src/options.c @@ -122,7 +122,8 @@ static void option_config_peer(const char *arg) { if(!fastd_config_read(arg, conf.peer_group, peer, 0)) exit(1); - fastd_peer_add(peer); + if (!fastd_peer_add(peer)) + exit_error("invalid peer definition"); } /** Handles the --config-peer-dir option */ -- cgit v1.2.3