- Timestamp:
- 2011-12-17T13:50:01Z (12 years ago)
- Branches:
- master
- Children:
- 18c6d36
- Parents:
- 87dddee (diff), 17f057d (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
irc_im.c
r87dddee r6e9ae72 197 197 irc_t *irc = bee->ui_data; 198 198 irc_user_t *iu = (irc_user_t *) bu->ui_data; 199 char *dst, *prefix = NULL; 199 const char *dst; 200 char *prefix = NULL; 200 201 char *wrapped, *ts = NULL; 201 irc_channel_t *ic = NULL;202 202 char *msg = g_strdup( msg_ ); 203 203 GSList *l; … … 206 206 ts = irc_format_timestamp( irc, sent_at ); 207 207 208 /* Too similar to irc_usermsg()... */ 209 if( iu->last_channel ) 210 { 211 if( iu->last_channel->flags & IRC_CHANNEL_JOINED ) 212 ic = iu->last_channel; 213 else 214 ic = irc_channel_with_user( irc, iu ); 215 } 216 217 if( ic ) 218 { 219 dst = ic->name; 208 dst = irc_user_msgdest( iu ); 209 if( dst != irc->user->nick ) 210 { 211 /* if not messaging directly, call user by name */ 220 212 prefix = g_strdup_printf( "%s%s%s", irc->user->nick, set_getstr( &bee->set, "to_char" ), ts ? : "" ); 221 213 } 222 214 else 223 215 { 224 dst = irc->user->nick;225 216 prefix = ts; 226 ts = NULL; 217 ts = NULL; /* don't double-free */ 227 218 } 228 219 … … 995 986 else if( !acc->prpl->chat_join ) 996 987 { 997 irc_ usermsg( ic->irc, "Named chatrooms not supported on that account." );988 irc_rootmsg( ic->irc, "Named chatrooms not supported on that account." ); 998 989 return SET_INVALID; 999 990 }
Note: See TracChangeset
for help on using the changeset viewer.