[Nagiosplug-checkins] SF.net SVN: nagiosplug: [1852] nagiosplug/trunk/plugins/check_http.c

psychotrahe at users.sourceforge.net psychotrahe at users.sourceforge.net
Mon Dec 10 02:13:56 CET 2007


Revision: 1852
          http://nagiosplug.svn.sourceforge.net/nagiosplug/?rev=1852&view=rev
Author:   psychotrahe
Date:     2007-12-09 17:13:55 -0800 (Sun, 09 Dec 2007)

Log Message:
-----------
Fix output when response time is critical. Thanks to Nobuhiro Ban (patch #1817228)

Modified Paths:
--------------
    nagiosplug/trunk/plugins/check_http.c

Modified: nagiosplug/trunk/plugins/check_http.c
===================================================================
--- nagiosplug/trunk/plugins/check_http.c	2007-12-10 00:19:27 UTC (rev 1851)
+++ nagiosplug/trunk/plugins/check_http.c	2007-12-10 01:13:55 UTC (rev 1852)
@@ -939,14 +939,14 @@
   microsec = deltime (tv);
   elapsed_time = (double)microsec / 1.0e6;
   asprintf (&msg,
-            _("HTTP WARNING: %s - %.3f second response time %s|%s %s\n"),
+            _(" - %s - %.3f second response time %s|%s %s\n"),
             status_line, elapsed_time, 
             (display_html ? "</A>" : ""),
             perfd_time (elapsed_time), perfd_size (pagesize));
   if (check_critical_time == TRUE && elapsed_time > critical_time)
-    die (STATE_CRITICAL, "%s", msg);
+    die (STATE_CRITICAL, "HTTP %s: %s", _("CRITICAL"), msg);
   if (check_warning_time == TRUE && elapsed_time > warning_time)
-    die (STATE_WARNING, "%s", msg);
+    die (STATE_WARNING, "HTTP %s: %s", _("WARNING"), msg);
 
   /* Page and Header content checks go here */
   /* these checks should be last */


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Commits mailing list