BUG/MINOR: srv: do not init address if backend is disabled
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Wed, 6 Jan 2021 13:28:50 +0000 (14:28 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 6 Jan 2021 15:57:17 +0000 (16:57 +0100)
commite3c419296211f08209300b9a06dc17467a6cb315
treec753d2ccddab96ff61ecf41405fbf9eea2afdbae
parent1e9a66603f0f827b214cbc7d9dd77147287da5b1
BUG/MINOR: srv: do not init address if backend is disabled

Do not proceed on init_addr if the backend of the server is marked as
disabled. When marked as disabled, the server is not fully initialized
and some operation must be avoided to prevent segfault. It is correct
because there is no way to activate a disabled backend.

This fixes the github issue #1031.
This should be backported to 2.2.
src/server.c