Initializes the configuration, validates it, and sets default values.
This function takes the preliminary Config object created by parse_command_line_args
, performs validation checks, sets default values for unspecified options, and ensures that the configuration is consistent and ready for use.
- Parameters
-
argc | The number of command-line arguments. |
argv | An array of strings containing the command-line arguments. |
- Returns
- A fully initialized and validated Config struct. The
error
field will be set to true
if any errors are encountered.