Code

threshold plugin: Dont check for interesting values if there are no thresholds.
authorSebastian Harl <sh@tokkee.org>
Fri, 17 Jun 2011 07:05:48 +0000 (09:05 +0200)
committerSebastian Harl <sh@tokkee.org>
Fri, 17 Jun 2011 07:05:48 +0000 (09:05 +0200)
src/threshold.c

index 7bbc59ef011a5f4a597b524f54a10852f1b725bf..88616e9501ab0abf7779122f610228e34237d4f8 100644 (file)
@@ -990,6 +990,10 @@ static int ut_missing (const value_list_t *vl,
   char identifier[6 * DATA_MAX_NAME_LEN];
   notification_t n;
 
+  /* dispatch notifications for "interesting" values only */
+  if (threshold_tree == NULL)
+    return (0);
+
   th = threshold_search (vl);
   if (th == NULL)
     return (0);