Mercurial > pidgin.yaz
comparison libpurple/protocols/qq/sendqueue.c @ 20126:5eb52c076a2f
Add disconnection reasons to qq
author | Will Thompson <will.thompson@collabora.co.uk> |
---|---|
date | Tue, 02 Oct 2007 00:27:50 +0000 |
parents | 44b4e8bd759b |
children | ba41f2a60253 |
comparison
equal
deleted
inserted
replaced
20125:3e8531514ad7 | 20126:5eb52c076a2f |
---|---|
118 if (p->resend_times == QQ_RESEND_MAX) { /* reach max */ | 118 if (p->resend_times == QQ_RESEND_MAX) { /* reach max */ |
119 switch (p->cmd) { | 119 switch (p->cmd) { |
120 case QQ_CMD_KEEP_ALIVE: | 120 case QQ_CMD_KEEP_ALIVE: |
121 if (qd->logged_in) { | 121 if (qd->logged_in) { |
122 purple_debug(PURPLE_DEBUG_ERROR, "QQ", "Connection lost!\n"); | 122 purple_debug(PURPLE_DEBUG_ERROR, "QQ", "Connection lost!\n"); |
123 purple_connection_error(gc, _("Connection lost")); | 123 purple_connection_error_reason(gc, |
124 PURPLE_REASON_NETWORK_ERROR, _("Connection lost")); | |
124 qd->logged_in = FALSE; | 125 qd->logged_in = FALSE; |
125 } | 126 } |
126 p->resend_times = -1; | 127 p->resend_times = -1; |
127 break; | 128 break; |
128 case QQ_CMD_LOGIN: | 129 case QQ_CMD_LOGIN: |
129 case QQ_CMD_REQUEST_LOGIN_TOKEN: | 130 case QQ_CMD_REQUEST_LOGIN_TOKEN: |
130 if (!qd->logged_in) /* cancel login progress */ | 131 if (!qd->logged_in) /* cancel login progress */ |
131 purple_connection_error(gc, _("Login failed, no reply")); | 132 purple_connection_error_reason(gc, |
133 PURPLE_REASON_NETWORK_ERROR, _("Login failed, no reply")); | |
132 p->resend_times = -1; | 134 p->resend_times = -1; |
133 break; | 135 break; |
134 default:{ | 136 default:{ |
135 purple_debug(PURPLE_DEBUG_WARNING, "QQ", | 137 purple_debug(PURPLE_DEBUG_WARNING, "QQ", |
136 "%s packet sent %d times but not acked. Not resending it.\n", | 138 "%s packet sent %d times but not acked. Not resending it.\n", |