mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-22 16:18:28 -05:00
Fix error "repl-backlog-size must be 1 or greater"
The parameter repl-backlog-size is not parsed correctly in the configuration file. argv[0] is parsed instead of argv[1].
This commit is contained in:
parent
18f537083a
commit
3d588b37ce
@ -240,7 +240,7 @@ void loadServerConfigFromString(char *config) {
|
|||||||
err = "argument must be 'yes' or 'no'"; goto loaderr;
|
err = "argument must be 'yes' or 'no'"; goto loaderr;
|
||||||
}
|
}
|
||||||
} else if (!strcasecmp(argv[0],"repl-backlog-size") && argc == 2) {
|
} else if (!strcasecmp(argv[0],"repl-backlog-size") && argc == 2) {
|
||||||
long long size = strtoll(argv[0],NULL,10);
|
long long size = strtoll(argv[1],NULL,10);
|
||||||
if (size <= 0) {
|
if (size <= 0) {
|
||||||
err = "repl-backlog-size must be 1 or greater.";
|
err = "repl-backlog-size must be 1 or greater.";
|
||||||
goto loaderr;
|
goto loaderr;
|
||||||
|
Loading…
Reference in New Issue
Block a user