comparison libpurple/protocols/simple/simple.c @ 32827:4a34689eeb33 default tip

merged from im.pidgin.pidgin
author Yoshiki Yazawa <yaz@honeyplanet.jp>
date Sat, 19 Nov 2011 14:42:54 +0900
parents 50cd80d3554e
children
comparison
equal deleted inserted replaced
32692:0f94ec89f0bc 32827:4a34689eeb33
1119 break; 1119 break;
1120 case 401: 1120 case 401:
1121 if(sip->registerstatus != SIMPLE_REGISTER_RETRY) { 1121 if(sip->registerstatus != SIMPLE_REGISTER_RETRY) {
1122 purple_debug_info("simple", "REGISTER retries %d\n", sip->registrar.retries); 1122 purple_debug_info("simple", "REGISTER retries %d\n", sip->registrar.retries);
1123 if(sip->registrar.retries > SIMPLE_REGISTER_RETRY_MAX) { 1123 if(sip->registrar.retries > SIMPLE_REGISTER_RETRY_MAX) {
1124 if (!purple_account_get_remember_password(sip->gc->account)) 1124 if (!purple_account_get_remember_password(purple_connection_get_account(sip->gc)))
1125 purple_account_set_password(sip->gc->account, NULL); 1125 purple_account_set_password(purple_connection_get_account(sip->gc), NULL);
1126 purple_connection_error(sip->gc, 1126 purple_connection_error(sip->gc,
1127 PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED, 1127 PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED,
1128 _("Incorrect password")); 1128 _("Incorrect password"));
1129 return TRUE; 1129 return TRUE;
1130 } 1130 }
1703 purple_debug_info("simple", "simple_input_cb: read error\n"); 1703 purple_debug_info("simple", "simple_input_cb: read error\n");
1704 connection_remove(sip, source); 1704 connection_remove(sip, source);
1705 if(sip->fd == source) sip->fd = -1; 1705 if(sip->fd == source) sip->fd = -1;
1706 return; 1706 return;
1707 } 1707 }
1708 gc->last_received = time(NULL); 1708 purple_connection_update_last_received(gc);
1709 conn->inbufused += len; 1709 conn->inbufused += len;
1710 conn->inbuf[conn->inbufused] = '\0'; 1710 conn->inbuf[conn->inbufused] = '\0';
1711 1711
1712 process_input(sip, conn); 1712 process_input(sip, conn);
1713 } 1713 }