Use loaderr label to handle error. (#9111)
So that we can easily see the lines of the config. Also unified with other error handling.
This commit is contained in:
parent
6248127c43
commit
89152f8e41
@ -487,9 +487,9 @@ void loadServerConfigFromString(char *config) {
|
||||
}
|
||||
} else if (!strcasecmp(argv[0],"dir") && argc == 2) {
|
||||
if (chdir(argv[1]) == -1) {
|
||||
serverLog(LL_WARNING,"Can't chdir to '%s': %s",
|
||||
argv[1], strerror(errno));
|
||||
exit(1);
|
||||
err = sdscatprintf(sdsempty(), "Can't chdir to '%s': %s",
|
||||
argv[1], strerror(errno));
|
||||
goto loaderr;
|
||||
}
|
||||
} else if (!strcasecmp(argv[0],"logfile") && argc == 2) {
|
||||
FILE *logfp;
|
||||
|
Loading…
x
Reference in New Issue
Block a user