Loading
config: Keep the Host state of an included file in that file
An included file that ends inside a Host or Match block for another
host left the parsing state off when it returned. The parser then
skipped every later line of the including file, and the next Include
lines with them, so a host defined in a second included file got none
of its options.
OpenSSH restores the state after each included file. Parse each
included file with its own copy of the state, so that a Host or Match
block ends with its file.
Fixes #380
Checklist
- Commits have
Signed-off-by:with name/author being identical to the commit author - Code modified for feature
- Test suite updated with functionality tests
- Test suite updated with negative tests
- Documentation updated
Reviewer's checklist:
- Any issues marked for closing are addressed
- There is a test suite reasonably covering new functionality or modifications
- Function naming, parameters, return values, types, etc., are consistent and according to CONTRIBUTING.md
- This feature/change has adequate documentation added
- No obvious mistakes in the code