comparison mcabber/src/hooks.c @ 1342:06441b6cc23a

History logfile: Use a special code (MI) for local MUC info messages (Suggested by bb)
author Mikael Berthe <mikael@lilotux.net>
date Sat, 03 Nov 2007 16:52:25 +0100
parents 1ea5a4cf2ae0
children 61a54e172010
comparison
equal deleted inserted replaced
1341:305f7a609545 1342:06441b6cc23a
169 // - We don't log the message if it is a private conf. message 169 // - We don't log the message if it is a private conf. message
170 // - We don't log the message if it is groupchat message and the log_muc_conf 170 // - We don't log the message if it is groupchat message and the log_muc_conf
171 // option is off (and it is not a history line) 171 // option is off (and it is not a history line)
172 if (!(message_flags & HBB_PREFIX_ERR) && 172 if (!(message_flags & HBB_PREFIX_ERR) &&
173 (!is_room || (is_groupchat && log_muc_conf && !timestamp))) 173 (!is_room || (is_groupchat && log_muc_conf && !timestamp)))
174 hlog_write_message(bjid, timestamp, FALSE, wmsg); 174 hlog_write_message(bjid, timestamp, 0, wmsg);
175 175
176 if (settings_opt_get_int("events_ignore_active_window") && 176 if (settings_opt_get_int("events_ignore_active_window") &&
177 current_buddy && scr_get_chatmode()) { 177 current_buddy && scr_get_chatmode()) {
178 gpointer bud = BUDDATA(current_buddy); 178 gpointer bud = BUDDATA(current_buddy);
179 if (bud) { 179 if (bud) {
251 // have the message twice... 251 // have the message twice...
252 scr_WriteOutgoingMessage(bjid, wmsg, (encrypted ? HBB_PREFIX_PGPCRYPT : 0)); 252 scr_WriteOutgoingMessage(bjid, wmsg, (encrypted ? HBB_PREFIX_PGPCRYPT : 0));
253 253
254 // We don't log private messages 254 // We don't log private messages
255 if (!nick) 255 if (!nick)
256 hlog_write_message(bjid, timestamp, TRUE, msg); 256 hlog_write_message(bjid, timestamp, 1, msg);
257 257
258 // External command 258 // External command
259 hk_ext_cmd(bjid, 'M', 'S', NULL); 259 hk_ext_cmd(bjid, 'M', 'S', NULL);
260 260
261 g_free(bmsg); 261 g_free(bmsg);