Explorar o código

fix: simplified exact match functionality

Griffin Westerman hai 1 ano
pai
achega
cba6658b69
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      plugins/check_dig.c

+ 1 - 1
plugins/check_dig.c

@@ -151,7 +151,7 @@ main (int argc, char **argv)
         }
 
         t = tt; /* consider the right-side token, does it match ex? */
-        if ( (!exact && strcasestr( t, ex )) || ((strcasestr( t, ex ) == t) && (strlen( t ) == strlen( ex ))) ) {
+        if ( (!exact && strcasestr( t, ex )) || (strcmp( t, ex ) == 0) ) {
           result = STATE_OK;
           msg = chld_out.line[i];
           break;