diff options
-rw-r--r-- | src/vty/telnet_interface.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/vty/telnet_interface.c b/src/vty/telnet_interface.c index 17588601..3fcae6ef 100644 --- a/src/vty/telnet_interface.c +++ b/src/vty/telnet_interface.c @@ -80,6 +80,9 @@ int telnet_init_dynif(void *tall_ctx, void *priv, const char *ip, int port) { int rc; + if (port < 0) + return -EINVAL; + tall_telnet_ctx = talloc_named_const(tall_ctx, 1, "telnet_connection"); |