BUG/MINOR: cli: Guard against NULL messages when using CLI_ST_PRINT_FREE
authorAurélien Nephtali <aurelien.nephtali@corp.ovh.com>
Mon, 16 Apr 2018 16:50:19 +0000 (18:50 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 16 Apr 2018 17:22:42 +0000 (19:22 +0200)
commitc511b7cc97482e7193aa19b8e571fa2ac851ea46
treeb715f4b1b3159cda6d3a1cceab8cc81939fc10c7
parent054fbee67a6e7bc7d396027ecc901f88255302cf
BUG/MINOR: cli: Guard against NULL messages when using CLI_ST_PRINT_FREE

Some error paths (especially those followed when running out of memory)
can set the error message to NULL. In order to avoid a crash, use a
generic message ("Out of memory") when this case arises.

It should be backported to 1.8.

Signed-off-by: Aurélien Nephtali <aurelien.nephtali@corp.ovh.com>
src/cli.c