Commit Diff


commit - f3705fdbf0d158f2fa6bffdccb37b390dc800da6
commit + 34f87d66a849d11bdcfa5326ddfcb354d05d077d
blob - dd68a3c71f89cb879d1ce0683a65d07f7fd8f474
blob + bafe39fddfcb8ac9a38af4e2ef813d393ea34044
--- opensmtpd.c
+++ opensmtpd.c
@@ -1042,14 +1042,16 @@ osmtpd_newline(struct io *io, int ev, __unused void *a
 		else if (strcmp(line, "config") == 0) {
 			line = end;
 			if (strcmp(line, "ready") == 0) {
-				conf_cb(NULL, NULL);
+				if (conf_cb != NULL)
+					conf_cb(NULL, NULL);
 				continue;
 			}
 			if ((end = strchr(line, '|')) == NULL)
 				osmtpd_errx(1, "Invalid line received: missing "
 				    "key: %s", linedup);
 			end++[0] = '\0';
-			conf_cb(line, end);
+			if (conf_cb != NULL)
+				conf_cb(line, end);
 			if (strcmp(line, "smtp-session-timeout") == 0) {
 				session_timeout = strtonum(end, 0, INT_MAX,
 				    &errstr);