Skip to content

Commit 6e16c21

Browse files
committed
Fix compilation error in get_config_path()
1 parent 1b60c84 commit 6e16c21

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/common.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ char *get_config_path(char* default_path, char* pbuf, size_t bufsize) {
1515
char *path = default_path;
1616
if(check_path(path))
1717
goto have;
18+
19+
if (!pbuf) {
20+
perror("couldnt find configuration file");
21+
exit(1);
22+
}
1823

1924
// priority 1: env var PROXYBOUND_CONF_FILE
2025
path = getenv(PROXYBOUND_CONF_FILE_ENV_VAR);

0 commit comments

Comments
 (0)