From 6f84a6574b097eba3f727e5f2b257309ca6c0e1b Mon Sep 17 00:00:00 2001
From: Ton Voon <tonvoon@users.sourceforge.net>
Date: Tue, 21 Mar 2006 13:31:01 +0000
Subject: Return CRITICAL if hostname invalid, as per guidelines

git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1335 f882894a-f735-0410-b71e-b25c423dba1c

diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c
index 08ec856..5915af2 100644
--- a/plugins/check_tcp.c
+++ b/plugins/check_tcp.c
@@ -549,7 +549,7 @@ process_arguments (int argc, char **argv)
 	if (server_address == NULL)
 		usage4 (_("You must provide a server address"));
 	else if (server_address[0] != '/' && is_host (server_address) == FALSE)
-		usage2 (_("Invalid hostname, address, or socket"), server_address);
+		die (STATE_CRITICAL, "%s: %s - %s\n", progname, _("Invalid hostname, address or socket"), server_address);
 
 	return TRUE;
 }
-- 
cgit v0.10-9-g596f

