aboutsummaryrefslogtreecommitdiffstats
path: root/irc_send.c
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2010-05-04 09:45:10 +0100
committerWilmer van der Gaast <wilmer@gaast.net>2010-05-04 09:45:10 +0100
commiteb504957c2ffa1a3130951d5381672fb3ef9dfd9 (patch)
tree25f88e020a30b762d70c8c88b00a39a2342786ed /irc_send.c
parent9893da32ab881e135748295fc5c48aada552098b (diff)
Show offline/away status better in /WHO and /WHOIS.
Diffstat (limited to 'irc_send.c')
-rw-r--r--irc_send.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/irc_send.c b/irc_send.c
index d3485221..b3283152 100644
--- a/irc_send.c
+++ b/irc_send.c
@@ -230,6 +230,10 @@ void irc_send_whois( irc_user_t *iu )
else
irc_send_num( irc, num, "%s :%s", iu->nick, bu->status ? : bu->status_msg );
}
+ else if( !( bu->flags & BEE_USER_ONLINE ) )
+ {
+ irc_send_num( irc, 301, "%s :%s", iu->nick, "User is offline" );
+ }
}
else
{
@@ -251,7 +255,8 @@ void irc_send_who( irc_t *irc, GSList *l, const char *channel )
/* TODO(wilmer): Restore away/channel information here */
irc_send_num( irc, 352, "%s %s %s %s %s %c :0 %s",
channel ? : "*", iu->user, iu->host, irc->root->host,
- iu->nick, 'H', iu->fullname );
+ iu->nick, iu->flags & IRC_USER_AWAY ? 'G' : 'H',
+ iu->fullname );
l = l->next;
}