diff options
| author | Kozlov Dmitry <dima@server> | 2010-12-30 13:53:40 +0300 |
|---|---|---|
| committer | Kozlov Dmitry <dima@server> | 2010-12-30 13:53:40 +0300 |
| commit | ad1b6c33dc19ffd4ca87cc6c787f0f670c307cfc (patch) | |
| tree | 3433a74bfaeeb1cab896e5932d4f5f31d0e4ea00 /accel-pptpd/cli/cli.c | |
| parent | f7058be535637cc5cee39a9b1aa852461cfb66fd (diff) | |
| download | accel-ppp-ad1b6c33dc19ffd4ca87cc6c787f0f670c307cfc.tar.gz accel-ppp-ad1b6c33dc19ffd4ca87cc6c787f0f670c307cfc.zip | |
cli: fixed crash if password is specified
cli: fixed exit command
Diffstat (limited to 'accel-pptpd/cli/cli.c')
| -rw-r--r-- | accel-pptpd/cli/cli.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/accel-pptpd/cli/cli.c b/accel-pptpd/cli/cli.c index 048809c..ef168de 100644 --- a/accel-pptpd/cli/cli.c +++ b/accel-pptpd/cli/cli.c @@ -181,7 +181,7 @@ int cli_process_cmd(struct cli_client_t *cln) case CLI_CMD_EXIT: cln->disconnect(cln); case CLI_CMD_FAILED: - return -1; + return 0; case CLI_CMD_SYNTAX: cli_send(cln, MSG_SYNTAX_ERROR); return 0; @@ -206,7 +206,7 @@ static void load_config(void) _free(conf_cli_passwd); opt = conf_get_opt("cli", "password"); if (opt) - conf_cli_passwd = _strdup(conf_cli_passwd); + conf_cli_passwd = _strdup(opt); else conf_cli_passwd = NULL; |
