Better error handling.

This commit is contained in:
7u83 2022-07-31 23:58:43 +02:00
parent 1616d77a0f
commit 6d9da94863
1 changed files with 4 additions and 1 deletions

View File

@ -368,5 +368,8 @@ int cw_cfg_load(const char *filename,cw_Cfg_t * cfg)
return errno;
errs = cw_cfg_read_from_file(f,cfg);
fclose(f);
return errs;
if (errs)
errno = EINVAL;
return errno;
}