Diff options
| author | Bryce Kwon <bryce@brycekwon.com> | |
|---|---|---|
| committer | Bryce Kwon <bryce@brycekwon.com> | |
| commit | ||
| parent | ||
| tree | ||
| download | ||
Report a cgitrc or include that cannot be read
A missing or unreadable cgitrc left only "No repositories found" and an
empty log, the commonest first mistake with no trace of its cause. A
scanned repository's own cgitrc stays quiet, since most have none.
Diffstat (limited to 'source/config.h')
| -rw-r--r-- | source/config.h | 6 |
1 file changed, 5 insertions, 1 deletion
diff --git a/source/config.h b/source/config.h index 3ddf974..30cf74d 100644 --- a/source/config.h +++ b/source/config.h @@ -9,6 +9,10 @@ typedef void (*config_file_value_fn)(const char *name, const char *value); -extern void config_file_parse(const char *filename, config_file_value_fn fn); +/* + * Returns 0, or an errno value when filename could not be opened or read. A + * missing file is ordinary for some callers, so reporting one is left to them. + */ +extern int config_file_parse(const char *filename, config_file_value_fn fn); #endif // CGIT_CONFIG_H |
