--- /home/icsrwi/proj/nagios-2.4-ORIG/base/checks.c	2006-02-15 21:47:55.000000000 -0700
+++ checks.c	2006-08-16 11:32:28.309124928 -0600
@@ -109,6 +109,7 @@
 	FILE *fp;
 	int pclose_result=0;
 	int time_is_valid=TRUE;
+	int neb_ret;
 #ifdef EMBEDDEDPERL
 	char fname[512];
 	char *args[5] = {"",DO_CLEAN, "", "", NULL };
@@ -268,7 +269,11 @@
 	/* send data to event broker */
 	end_time.tv_sec=0L;
 	end_time.tv_usec=0L;
-	broker_service_check(NEBTYPE_SERVICECHECK_INITIATE,NEBFLAG_NONE,NEBATTR_NONE,svc,SERVICE_CHECK_ACTIVE,start_time,end_time,svc->service_check_command,svc->latency,0.0,0,FALSE,0,processed_command,NULL);
+	neb_ret = broker_service_check(NEBTYPE_SERVICECHECK_INITIATE,NEBFLAG_NONE,NEBATTR_NONE,svc,SERVICE_CHECK_ACTIVE,start_time,end_time,svc->service_check_command,svc->latency,0.0,0,FALSE,0,processed_command,NULL);
+
+	/* check for override from module callback */
+	if (neb_ret == NEBERROR_CALLBACKOVERRIDE)
+		return;
 #endif
 
 #ifdef EMBEDDEDPERL