# HG changeset patch # User Daniel Atallah # Date 1157830894 0 # Node ID af856551902b5e0ecc8db8a2a1e51dbfd5c159e5 # Parent a5c7db7be826ba7107d00dd675924486885aab0c [gaim-migrate @ 17202] Don't register the connection keepalive timer if the prpl doesn't support keepalives committer: Tailor Script diff -r a5c7db7be826 -r af856551902b libgaim/connection.c --- a/libgaim/connection.c Sat Sep 09 19:39:31 2006 +0000 +++ b/libgaim/connection.c Sat Sep 09 19:41:34 2006 +0000 @@ -61,6 +61,14 @@ static void update_keepalive(GaimConnection *gc, gboolean on) { + GaimPluginProtocolInfo *prpl_info = NULL; + + if (gc != NULL && gc->prpl != NULL) + prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl); + + if (!prpl_info || !prpl_info->keepalive) + return; + if (on && !gc->keepalive) { gaim_debug_info("connection", "Activating keepalive.\n");