A memory allocation failure happening in http_parse_redirect_rule when
trying to allocate a redirect_rule structure would have resulted in a
crash. This function is only called during configuration parsing.
It was raised in GitHub issue #1233.
It could be backported to all stable branches.
}
rule = calloc(1, sizeof(*rule));
+ if (!rule) {
+ memprintf(errmsg, "parsing [%s:%d]: out of memory.", file, linenum);
+ return NULL;
+ }
rule->cond = cond;
LIST_INIT(&rule->rdr_fmt);