diff options
| -rw-r--r-- | hardinfo2/arch/common/users.h | 2 | ||||
| -rw-r--r-- | hardinfo2/ssh-conn.c | 6 | 
2 files changed, 5 insertions, 3 deletions
| diff --git a/hardinfo2/arch/common/users.h b/hardinfo2/arch/common/users.h index 31d0b719..8d087fa5 100644 --- a/hardinfo2/arch/common/users.h +++ b/hardinfo2/arch/common/users.h @@ -58,4 +58,6 @@ scan_users_do(void)          users = h_strdup_cprintf("$%s$%s=%s\n", users, key, passwd_->pw_name, passwd_->pw_gecos);          passwd_ = getpwent();      } +     +    endpwent();  } diff --git a/hardinfo2/ssh-conn.c b/hardinfo2/ssh-conn.c index d73c2a57..b14310c2 100644 --- a/hardinfo2/ssh-conn.c +++ b/hardinfo2/ssh-conn.c @@ -249,13 +249,13 @@ SSHConnResponse ssh_new(SoupURI * uri,      if (bytes_read > 0 && res == 1) {  	DEBUG("Received (error channel): [%s]", buffer); -	if (g_str_has_prefix(buffer, "Permission denied")) { +	if (strstr(buffer, "Permission denied")) {  	    response = SSH_CONN_PERMISSION_DENIED;  	    goto end; -	} else if (g_str_has_prefix(buffer, "Host key verification failed")) { +	} else if (strstr(buffer, "Host key verification failed")) {  	    response = SSH_CONN_HOST_KEY_CHECK_FAIL;  	    goto end; -	} else if (g_str_has_prefix(buffer, "Connection refused")) { +	} else if (strstr(buffer, "Connection refused")) {  	    response = SSH_CONN_REFUSED;  	    goto end;  	} | 
