From d74b81b61e87c66d364a8590a48d87773ad2652c Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Thu, 30 Aug 2012 14:00:34 +0200 Subject: [PATCH] Fix node name check for "connect" and "disconnect" commands. --- src/tincctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tincctl.c b/src/tincctl.c index fa52533..00d8eb9 100644 --- a/src/tincctl.c +++ b/src/tincctl.c @@ -928,7 +928,7 @@ static int cmd_connect(int argc, char *argv[]) { return 1; } - if(!check_id(argv[2])) { + if(!check_id(argv[1])) { fprintf(stderr, "Invalid name for node.\n"); return 1; } @@ -951,7 +951,7 @@ static int cmd_disconnect(int argc, char *argv[]) { return 1; } - if(!check_id(argv[2])) { + if(!check_id(argv[1])) { fprintf(stderr, "Invalid name for node.\n"); return 1; } -- 2.25.1