pidgin: e83f93ec: Add some safety to jabber_send_signal_cb...
paul at darkrain42.org
Thu Nov 26 13:30:01 EST 2009
On Nov 25, 2009, at 11:08, nosnilmot at pidgin.im wrote:
> Modified files:
> Add some safety to jabber_send_signal_cb in case someone else was listening
> to jabber-sending-xmlnode and caused the connection to get disconnected
> before the signal got to calling jabber_send_signal_cb. Should fix
I'm not convinced this is how the crash is occurring.
From the backtrace, frame 10 indicates this code path is being triggered by a FT request denial. I'm guessing the FT request dialog isn't closed when an account disconnects (I don't have Pidgin handy, so I can't confirm that, but the request dialog uses the xfer as the purple_request_ handle, not gc).
It seems like a better (and more general) solution would be to close all xfers when an account disconnects, otherwise crashes like this probably exist in other prpls (unless they also use PURPLE_CONNECTION_IS_VALID).
> --- libpurple/protocols/jabber/jabber.c 80eb4367a92a0b7ae0d294d52a96c6cd65dcca04
> +++ libpurple/protocols/jabber/jabber.c c2a68c8d08099a3020f7c42ae07be750393b222c
> @@ -476,7 +476,14 @@ void jabber_send_signal_cb(PurpleConnect
> if (NULL == packet)
> + if (!PURPLE_CONNECTION_IS_VALID(pc))
> + return;
> js = purple_connection_get_protocol_data(pc);
> + if (NULL == js)
> + return;
> if (js->bosh)
> if (g_str_equal((*packet)->name, "message") ||
> g_str_equal((*packet)->name, "iq") ||
More information about the Devel