mirror of
https://github.com/curl/curl.git
synced 2026-07-31 22:08:05 +03:00
tool_parsecfg: detect and error on recursive --config use
The config file parser now has a maximum level of inclusions allowed (5) to detect and prevent recursive inclusions of itself leading to badness. Bonus: clean up return code handling from the config parser. Test 774 verifies Closes #19168
This commit is contained in:
parent
b4f57c8045
commit
9e198618de
10 changed files with 72 additions and 32 deletions
|
|
@ -40,8 +40,6 @@ const char *param2text(ParameterError error)
|
|||
return "had unsupported trailing garbage";
|
||||
case PARAM_OPTION_UNKNOWN:
|
||||
return "is unknown";
|
||||
case PARAM_OPTION_AMBIGUOUS:
|
||||
return "is ambiguous";
|
||||
case PARAM_REQUIRES_PARAMETER:
|
||||
return "requires parameter";
|
||||
case PARAM_BAD_USE:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue