re-added some NULL check at run-time, with an error message on stderr

This commit is contained in:
Marc Stern
2024-08-14 13:53:52 +02:00
parent 8dd5d5f46b
commit e5bbd89399
3 changed files with 305 additions and 1 deletions

View File

@@ -2385,6 +2385,11 @@ msre_rule *msre_rule_create(msre_ruleset *ruleset, int type,
assert(ruleset != NULL);
assert(args != NULL);
assert(error_msg != NULL);
// Normally useless code, left to be safe for the moment
if (error_msg == NULL) {
ap_log_perror(APLOG_MARK, APLOG_EMERG, 0, ruleset->mp, NULL, "msre_rule_create: error_msg is NULL");
return NULL;
}
msre_rule *rule;
char *my_error_msg;
const char *argsp;