src/protocols/irc/cmds.c

changeset 9130
2e67295dd047
parent 8624
726fdb74d4d3
child 9248
a0d666471c19
equal deleted inserted replaced
9129:9510867e614f 9130:2e67295dd047
109 g_free(newargs[0]); 109 g_free(newargs[0]);
110 g_free(newargs[1]); 110 g_free(newargs[1]);
111 g_free(newargs); 111 g_free(newargs);
112 112
113 convo = gaim_find_conversation_with_account(target, irc->account); 113 convo = gaim_find_conversation_with_account(target, irc->account);
114 if (convo && gaim_conversation_get_type(convo) == GAIM_CONV_CHAT) { 114 if (convo) {
115 action = g_strdup_printf("/me %s", args[0]); 115 action = g_strdup_printf("/me %s", args[0]);
116 if (action[strlen(action) - 1] == '\n') 116 if (action[strlen(action) - 1] == '\n')
117 action[strlen(action) - 1] = '\0'; 117 action[strlen(action) - 1] = '\0';
118 serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)), 118 if (gaim_conversation_get_type(convo) == GAIM_CONV_CHAT)
119 gaim_connection_get_display_name(gc), 119 serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
120 0, action, time(NULL)); 120 gaim_connection_get_display_name(gc),
121 0, action, time(NULL));
122 else
123 gaim_conv_im_write(GAIM_CONV_IM(convo), gaim_connection_get_display_name(gc),
124 action, 0, time(NULL));
121 g_free(action); 125 g_free(action);
122 } 126 }
123 127
124 return 1; 128 return 1;
125 } 129 }

mercurial