]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: startup: leave at first post_section_parser which fails
authorWilliam Lallemand <wlallemand@haproxy.com>
Mon, 17 Feb 2025 09:59:46 +0000 (10:59 +0100)
committerWilliam Lallemand <wlallemand@haproxy.com>
Mon, 17 Feb 2025 10:21:20 +0000 (11:21 +0100)
commit7268e9c2495020d4d9d6feca086fc1584954d792
treedf8e97f82dbcd6685bf5825549fb82659494a001
parent32691e7c255a944224e0ac17d0f83f217be6c5d6
BUG/MINOR: startup: leave at first post_section_parser which fails

Since we are now iterating on post_section_parser() for a same keyword,
we need to exit at the first ERR_ABORT.

The post_section_parser() is called when parsing a new section, but also
at the end of the file to be called for the last section.

The changes in 4de86bb ("MEDIUM: initcall: allow to register mutiple
post_section_parser per section") should have added tests on the
ERR_ABORT value.

Also pcs->post_section_parser() must be called instead of
cs->post_section_parser() because we could have a NULL ptr.

This bug does not affect anything since we don't use
REGISTER_CONFIG_POST_SECTION() yet.
src/cfgparse.c