summaryrefslogtreecommitdiff
path: root/libpurple/connection.h
diff options
context:
space:
mode:
authorWill Thompson <resiak@pidgin.im>2007-11-11 19:09:49 +0000
committerWill Thompson <resiak@pidgin.im>2007-11-11 19:09:49 +0000
commitbe75af7a530ab6abef7d3c9cc4f08c784f913f43 (patch)
treeb64994a77b0baf3d90b819ccece5b750325836d5 /libpurple/connection.h
parent6b7cfc6a0cfc358a0d2609883f40cf7124c67f38 (diff)
downloadpidgin-be75af7a530ab6abef7d3c9cc4f08c784f913f43.tar.gz
Add PURPLE_CONNECTION_ERROR_{INVALID_USERNAME,INCORRECT_PASSWORD}, to be used
rather than _AUTHENTICATION_FAILED when it is known that the username/password was incorrect (for example, on AIM).
Diffstat (limited to 'libpurple/connection.h')
-rw-r--r--libpurple/connection.h38
1 files changed, 22 insertions, 16 deletions
diff --git a/libpurple/connection.h b/libpurple/connection.h
index 620cd6156c..67aa61d6e5 100644
--- a/libpurple/connection.h
+++ b/libpurple/connection.h
@@ -64,26 +64,32 @@ typedef enum
* data).
*/
PURPLE_CONNECTION_ERROR_NETWORK_ERROR = 0,
- /** The username or password (or some other credential) was incorrect.
+ /** The username supplied was not valid. */
+ PURPLE_CONNECTION_ERROR_INVALID_USERNAME = 1,
+ /** The password was incorrect. */
+ PURPLE_CONNECTION_ERROR_INCORRECT_PASSWORD = 2,
+ /** The username, password or some other credential was incorrect. Use
+ * the above two errors if the username or password in particular are
+ * known to be incorrect.
*/
- PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED = 1,
+ PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED = 3,
/** libpurple doesn't speak any of the authentication methods the
* server offered.
*/
- PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE = 2,
+ PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE = 4,
/** libpurple was built without SSL support, and the connection needs
* SSL.
*/
- PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT = 3,
+ PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT = 5,
/** There was an error negotiating SSL on this connection, or the
* server does not support encryption but an account option was set to
* require it.
*/
- PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR = 4,
+ PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR = 6,
/** Someone is already connected to the server using the name you are
* trying to connect with.
*/
- PURPLE_CONNECTION_ERROR_NAME_IN_USE = 5,
+ PURPLE_CONNECTION_ERROR_NAME_IN_USE = 7,
/** The username/server/other preference for the account isn't valid.
* For instance, on IRC the screen name cannot contain white space.
@@ -94,27 +100,27 @@ typedef enum
* other account preferences should be validated when the
* account is created.
*/
- PURPLE_CONNECTION_ERROR_INVALID_SETTINGS = 6,
+ PURPLE_CONNECTION_ERROR_INVALID_SETTINGS = 8,
/** The server did not provide a SSL certificate. */
- PURPLE_CONNECTION_ERROR_CERT_NOT_PROVIDED = 7,
+ PURPLE_CONNECTION_ERROR_CERT_NOT_PROVIDED = 9,
/** The server's SSL certificate could not be trusted. */
- PURPLE_CONNECTION_ERROR_CERT_UNTRUSTED = 8,
+ PURPLE_CONNECTION_ERROR_CERT_UNTRUSTED = 10,
/** The server's SSL certificate has expired. */
- PURPLE_CONNECTION_ERROR_CERT_EXPIRED = 9,
+ PURPLE_CONNECTION_ERROR_CERT_EXPIRED = 11,
/** The server's SSL certificate is not yet valid. */
- PURPLE_CONNECTION_ERROR_CERT_NOT_ACTIVATED = 10,
+ PURPLE_CONNECTION_ERROR_CERT_NOT_ACTIVATED = 12,
/** The server's SSL certificate did not match its hostname. */
- PURPLE_CONNECTION_ERROR_CERT_HOSTNAME_MISMATCH = 11,
+ PURPLE_CONNECTION_ERROR_CERT_HOSTNAME_MISMATCH = 13,
/** The server's SSL certificate does not have the expected
* fingerprint.
*/
- PURPLE_CONNECTION_ERROR_CERT_FINGERPRINT_MISMATCH = 12,
+ PURPLE_CONNECTION_ERROR_CERT_FINGERPRINT_MISMATCH = 14,
/** The server's SSL certificate is self-signed. */
- PURPLE_CONNECTION_ERROR_CERT_SELF_SIGNED = 13,
+ PURPLE_CONNECTION_ERROR_CERT_SELF_SIGNED = 15,
/** There was some other error validating the server's SSL certificate.
*/
- PURPLE_CONNECTION_ERROR_CERT_OTHER_ERROR = 14,
+ PURPLE_CONNECTION_ERROR_CERT_OTHER_ERROR = 16,
/** Some other error occured which fits into none of the other
* categories.
@@ -123,7 +129,7 @@ typedef enum
* this is the last member of the enum when sanity-checking; if other
* reasons are added after it, the check must be updated.
*/
- PURPLE_CONNECTION_ERROR_OTHER_ERROR = 15
+ PURPLE_CONNECTION_ERROR_OTHER_ERROR = 17
} PurpleConnectionError;
/** Holds the type of an error along with its description. */