aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libssh/sftp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libssh/sftp.c b/libssh/sftp.c
index 34a0aee5..bc5e6379 100644
--- a/libssh/sftp.c
+++ b/libssh/sftp.c
@@ -748,7 +748,7 @@ static sftp_status_message parse_status_msg(sftp_message msg){
}
status->error = buffer_get_ssh_string(msg->payload);
status->lang = buffer_get_ssh_string(msg->payload);
- if(status->error != NULL || status->lang != NULL){
+ if(status->error == NULL || status->lang == NULL){
if(msg->sftp->version >=3){
/* These are mandatory from version 3 */
string_free(status->error);