mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 20:30:38 +09:00
config: Bugfix: Don't skip unseen opcodes
libssh fails to read the configuration from a config file due to a
wrong check in 'ssh_config_parse_line' procedure in 'config.c'; it's
effectively skipping every opcode (and therefore every option) from
the file. The change fixes that behaviour.
Signed-off-by: Artyom V. Poptsov <poptsov.artyom@gmail.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
(cherry picked from commit 5333be5988)
This commit is contained in:
committed by
Andreas Schneider
parent
239d0f75b5
commit
83663895f4
@@ -219,7 +219,7 @@ static int ssh_config_parse_line(ssh_session session, const char *line,
|
||||
|
||||
opcode = ssh_config_get_opcode(keyword);
|
||||
if (*parsing == 1 && opcode != SOC_HOST) {
|
||||
if (seen[opcode] == 0) {
|
||||
if (seen[opcode] != 0) {
|
||||
return 0;
|
||||
}
|
||||
seen[opcode] = 1;
|
||||
|
||||
Reference in New Issue
Block a user