]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
avoid NPR if helper is NULL
authorwessels <>
Sun, 18 Oct 1998 14:29:09 +0000 (14:29 +0000)
committerwessels <>
Sun, 18 Oct 1998 14:29:09 +0000 (14:29 +0000)
src/helper.cc

index 1ca20dff53bb6fefd7621c22dff1131f4b0862db..c0ed0b75f5ca39c03b30294250dd3d84ba133f46 100644 (file)
@@ -94,6 +94,11 @@ helperSubmit(helper * hlp, const char *buf, HLPCB * callback, void *data)
 {
     helper_request *r = xcalloc(1, sizeof(*r));
     helper_server *srv;
+    if (hlp == NULL) {
+       debug(29,3)("helperSubmit: hlp == NULL\n");
+       callback(data, NULL);
+       return;
+    }
     r->callback = callback;
     r->data = data;
     r->buf = xstrdup(buf);