aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2010-05-14 01:09:29 +0100
committerWilmer van der Gaast <wilmer@gaast.net>2010-05-14 01:09:29 +0100
commit6e6b3d7c7300c5cf5cf7f1538154925fd2fe3953 (patch)
treebea909bc9b2fc24230610126b9a22d8764f893dd
parent3742fb6ae99c2e5e25cff272a154b9834866e8f9 (diff)
Add a warning when the user included a domain part in his/her Yahoo! username.
-rw-r--r--protocols/yahoo/yahoo.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/protocols/yahoo/yahoo.c b/protocols/yahoo/yahoo.c
index 922ac17b..e4d541d5 100644
--- a/protocols/yahoo/yahoo.c
+++ b/protocols/yahoo/yahoo.c
@@ -137,10 +137,15 @@ static void byahoo_login( account_t *acc )
{
struct im_connection *ic = imcb_new( acc );
struct byahoo_data *yd = ic->proto_data = g_new0( struct byahoo_data, 1 );
+ char *s;
yd->logged_in = FALSE;
yd->current_status = YAHOO_STATUS_AVAILABLE;
+ if( ( s = strchr( acc->user, '@' ) ) && g_strcasecmp( s, "@yahoo.com" ) == 0 )
+ imcb_error( ic, "Your Yahoo! username should just be a username. "
+ "Do not include any @domain part." );
+
imcb_log( ic, "Connecting" );
yd->y2_id = yahoo_init( acc->user, acc->pass );
yahoo_login( yd->y2_id, yd->current_status );