aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2006-01-23 15:20:18 +0100
committerWilmer van der Gaast <wilmer@gaast.net>2006-01-23 15:20:18 +0100
commita91ecee010fdbd8e62e874e23a443206a48308c0 (patch)
tree86b4a16137c9a5b808e7b2bc0a009c95a6814853
parent87de505f3203054a2a0becbea5a064d24ab2cde3 (diff)
/AWAY now only sets the IM-protocols away that belong to the current IRC
/connection (was an issue in single-process daemon mode).
-rw-r--r--irc_commands.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/irc_commands.c b/irc_commands.c
index 9e47b83b..66c39bc5 100644
--- a/irc_commands.c
+++ b/irc_commands.c
@@ -414,8 +414,8 @@ static void irc_cmd_topic( irc_t *irc, char **cmd )
static void irc_cmd_away( irc_t *irc, char **cmd )
{
user_t *u = user_find( irc, irc->nick );
- GSList *c = get_connections();
char *away = cmd[1];
+ account_t *a;
if( !u ) return;
@@ -442,12 +442,12 @@ static void irc_cmd_away( irc_t *irc, char **cmd )
irc_reply( irc, 305, ":Welcome back" );
}
- while( c )
+ for( a = irc->accounts; a; a = a->next )
{
- if( ((struct gaim_connection *)c->data)->flags & OPT_LOGGED_IN )
- proto_away( c->data, u->away );
+ struct gaim_connection *gc = a->gc;
- c = c->next;
+ if( gc && gc->flags & OPT_LOGGED_IN )
+ proto_away( gc, u->away );
}
}