diff options
author | eionrobb <eionrobb@8ca6c67d-4297-256d-f884-781da6d5760b> | 2014-01-15 00:15:20 +0400 |
---|---|---|
committer | eionrobb <eionrobb@8ca6c67d-4297-256d-f884-781da6d5760b> | 2014-01-15 00:15:20 +0400 |
commit | 331c8a301a3089295057aeeffeb7fbc9aa651db0 (patch) | |
tree | bbeed6d014b1a53bf65b861833b02075b94dde28 | |
parent | b142e0748b4426289177103188c9bb1697ee1039 (diff) |
Don't disable the account if there was a non-authentication error during login
-rw-r--r-- | steam-mobile/libsteam.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/steam-mobile/libsteam.c b/steam-mobile/libsteam.c index 8a9614a..e257b4e 100644 --- a/steam-mobile/libsteam.c +++ b/steam-mobile/libsteam.c @@ -896,7 +896,7 @@ steam_login_access_token_cb(SteamAccount *sa, JsonObject *obj, gpointer user_dat if (!g_str_equal(json_object_get_string_member(obj, "error"), "OK"))
{
purple_debug_error("steam", "access_token login error: %s\n", json_object_get_string_member(obj, "error"));
- purple_connection_error(sa->pc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, _("Bad username/password or Steam Guard Code required"));
+ purple_connection_error(sa->pc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, json_object_get_string_member(obj, "error"));
return;
}
@@ -929,6 +929,13 @@ steam_login_with_access_token_error_cb(SteamAccount *sa, const gchar *data, gssi steam_account_set_access_token(sa, NULL);
steam_get_rsa_key(sa);
+ } else {
+ xmlnode *error_response = xmlnode_from_str(data, data_len);
+ xmlnode *title = xmlnode_get_child(error_response, "title");
+ gchar *title_str = xmlnode_get_data_unescaped(title);
+ purple_connection_error(sa->pc, PURPLE_CONNECTION_ERROR_NETWORK_ERROR, title_str);
+ g_free(title_str);
+ xmlnode_free(error_response);
}
}
|