problem with PURPLE_MESSAGE_AUTO_RESP
Kim Stebel
kim.stebel at googlemail.com
Mon Sep 28 11:13:29 EDT 2009
Hello List!
I'd like to ask for your help with a problem with a plugin I wrote. This plugin replies to certain messages automatically and this can get into an infinite loop if both users use the plugin. I thought this could be fixed like that:
/*Sending*/
PurpleMessageFlags flags = PURPLE_MESSAGE_SEND | PURPLE_MESSAGE_AUTO_RESP;
serv_send_im(gc, who, reply, flag);
purple_debug_misc(PLUGIN_ID, "flags sent = %d\n", flags);
/*Receiving*/
purple_debug_misc(PLUGIN_ID, "flags received = %d\n", flags);
if (flags & PURPLE_MESSAGE_AUTO_RESP) {
return; //do not send autoreply message
}
Unfortunately it doesn't work. The flags received don't match the flags sent. I get sent = 9 and received = 2. Please enlighten me.
Kim
More information about the Devel
mailing list