diff options
Diffstat (limited to 'src/options.c')
-rw-r--r-- | src/options.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/options.c b/src/options.c index 931cb31..d389f7c 100644 --- a/src/options.c +++ b/src/options.c @@ -780,11 +780,15 @@ int ssh_options_set(ssh_session session, enum ssh_options_e type, return -1; } else { SAFE_FREE(session->opts.ProxyCommand); - q = strdup(v); - if (q == NULL) { - return -1; + /* Setting the command to 'none' disables this option. */ + rc = strcasecmp(v, "none"); + if (rc != 0) { + q = strdup(v); + if (q == NULL) { + return -1; + } + session->opts.ProxyCommand = q; } - session->opts.ProxyCommand = q; } break; default: |