Mercurial > pidgin
comparison libpurple/protocols/sametime/sametime.c @ 20778:8174f6999308
Sprinkle gc->wants_to_die = TRUE liberally around connection errors that really
ought to have been setting it already so that it is always set when a
disconnection reason is fatal. In a couple of other places, fix the reason to
be more accurate and not be fatal.
author | Will Thompson <will.thompson@collabora.co.uk> |
---|---|
date | Fri, 05 Oct 2007 18:33:27 +0000 |
parents | 57e9d1ecefff |
children | efa448405f3d |
comparison
equal
deleted
inserted
replaced
20777:c40416c4eca6 | 20778:8174f6999308 |
---|---|
1561 | 1561 |
1562 case USER_RESTRICTED: | 1562 case USER_RESTRICTED: |
1563 case INCORRECT_LOGIN: | 1563 case INCORRECT_LOGIN: |
1564 case USER_UNREGISTERED: | 1564 case USER_UNREGISTERED: |
1565 case GUEST_IN_USE: | 1565 case GUEST_IN_USE: |
1566 gc->wants_to_die = TRUE; | |
1566 reason = PURPLE_REASON_AUTHENTICATION_FAILED; | 1567 reason = PURPLE_REASON_AUTHENTICATION_FAILED; |
1567 break; | 1568 break; |
1568 | 1569 |
1569 case ENCRYPT_MISMATCH: | 1570 case ENCRYPT_MISMATCH: |
1570 case ERR_ENCRYPT_NO_SUPPORT: | 1571 case ERR_ENCRYPT_NO_SUPPORT: |
1571 case ERR_NO_COMMON_ENCRYPT: | 1572 case ERR_NO_COMMON_ENCRYPT: |
1573 gc->wants_to_die = TRUE; | |
1572 reason = PURPLE_REASON_ENCRYPTION_ERROR; | 1574 reason = PURPLE_REASON_ENCRYPTION_ERROR; |
1573 break; | 1575 break; |
1574 | 1576 |
1575 case VERIFICATION_DOWN: | 1577 case VERIFICATION_DOWN: |
1576 reason = PURPLE_REASON_AUTHENTICATION_IMPOSSIBLE; | 1578 reason = PURPLE_REASON_AUTHENTICATION_IMPOSSIBLE; |
1577 break; | 1579 break; |
1578 | 1580 |
1579 case MULTI_SERVER_LOGIN: | 1581 case MULTI_SERVER_LOGIN: |
1580 case MULTI_SERVER_LOGIN2: | 1582 case MULTI_SERVER_LOGIN2: |
1583 gc->wants_to_die = TRUE; | |
1581 reason = PURPLE_REASON_NAME_IN_USE; | 1584 reason = PURPLE_REASON_NAME_IN_USE; |
1582 break; | 1585 break; |
1583 | 1586 |
1584 default: | 1587 default: |
1585 reason = PURPLE_REASON_NETWORK_ERROR; | 1588 reason = PURPLE_REASON_NETWORK_ERROR; |
3644 static void mw_prpl_login(PurpleAccount *acct); | 3647 static void mw_prpl_login(PurpleAccount *acct); |
3645 | 3648 |
3646 | 3649 |
3647 static void prompt_host_cancel_cb(PurpleConnection *gc) { | 3650 static void prompt_host_cancel_cb(PurpleConnection *gc) { |
3648 const char *msg = _("No Sametime Community Server specified"); | 3651 const char *msg = _("No Sametime Community Server specified"); |
3652 gc->wants_to_die = TRUE; | |
3649 purple_connection_error_reason(gc, PURPLE_REASON_INVALID_SETTINGS, msg); | 3653 purple_connection_error_reason(gc, PURPLE_REASON_INVALID_SETTINGS, msg); |
3650 } | 3654 } |
3651 | 3655 |
3652 | 3656 |
3653 static void prompt_host_ok_cb(PurpleConnection *gc, const char *host) { | 3657 static void prompt_host_ok_cb(PurpleConnection *gc, const char *host) { |