]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: compression: Add OOM check for calloc() in parse_compression_options()
authorAlexander Stephan <alexander.stephan@sap.com>
Mon, 1 Sep 2025 09:57:51 +0000 (09:57 +0000)
committerWilly Tarreau <w@1wt.eu>
Tue, 2 Sep 2025 05:29:54 +0000 (07:29 +0200)
commitaa20905ac9e45c6caa8929f4686020708209e2bf
treea098492047e63a8c92488f0103e75ba7412ead12
parent73f9a75894c660dd034439e0bc343aa00489dbc9
BUG/MINOR: compression: Add OOM check for calloc() in parse_compression_options()

This patch adds a missing out-of-memory (OOM) check after
the call to `calloc()` in `parse_compression_options()`. If
memory allocation fails, an error message is set, the function
returns -1, and parsing is aborted to ensure safe handling
of low-memory conditions.

Co-authored-by: Christian Norbert Menges <christian.norbert.menges@sap.com>
src/flt_http_comp.c