BUG/MINOR: worker: Missing calloc return value check in mworker_env_to_proc_list
authorRemi Tricot-Le Breton <rlebreton@haproxy.com>
Wed, 19 May 2021 08:45:12 +0000 (10:45 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Mon, 31 May 2021 08:51:06 +0000 (10:51 +0200)
commit1f4fa906c73e61dba74f9e8b762da12df3052f57
tree55038548cd0706ab2fcd9d8617c6d159b01ee370
parent6443bcc2e1f2e1e11af76ef460d8241f06223de8
BUG/MINOR: worker: Missing calloc return value check in mworker_env_to_proc_list

A memory allocation failure happening in mworker_env_to_proc_list when
trying to allocate a mworker_proc would have resulted in a crash. This
function is only called during init.

It was raised in GitHub issue #1233.
It could be backported to all stable branches.
include/haproxy/mworker.h
src/haproxy.c
src/mworker.c