Mercurial > hg
changeset 1998:41667bc02883
Fix GCC warnings (variables set but not used)
author | Myhailo Danylenko <isbear@ukrpost.net> |
---|---|
date | Sun, 24 Jul 2011 13:30:47 +0200 |
parents | 555e342556e7 |
children | 51f032d5ca22 |
files | mcabber/mcabber/xmpp.c |
diffstat | 1 files changed, 6 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/mcabber/mcabber/xmpp.c Sun May 22 23:54:32 2011 +0200 +++ b/mcabber/mcabber/xmpp.c Sun Jul 24 13:30:47 2011 +0200 @@ -324,8 +324,10 @@ #endif #if defined XEP0022 || defined XEP0085 LmMessageNode *event; + struct xep0085 *xep85 = NULL; +#if defined XEP0022 guint use_xep85 = 0; - struct xep0085 *xep85 = NULL; +#endif #endif gchar *enc = NULL; @@ -456,8 +458,10 @@ lm_message_node_set_attribute(event, "xmlns", NS_CHATSTATES); if (xep85->support == CHATSTATES_SUPPORT_UNKNOWN) xep85->support = CHATSTATES_SUPPORT_PROBED; +#ifdef XEP0022 else use_xep85 = 1; +#endif xep85->last_state_sent = ROSTER_EVENT_ACTIVE; } #endif @@ -971,7 +975,6 @@ { #if defined XEP0022 || defined XEP0085 LmMessageNode *state_ns = NULL; - const char *body; char *rname, *bjid; GSList *sl_buddy; guint events; @@ -1023,8 +1026,6 @@ return; } - body = lm_message_node_get_child_value(node, "body"); - if (which_xep == XEP_85) { /* XEP-0085 */ xep85->support = CHATSTATES_SUPPORT_OK; @@ -1042,6 +1043,7 @@ events = xep85->last_state_rcvd; } else { /* XEP-0022 */ #ifdef XEP0022 + const char *body = lm_message_node_get_child_value(node, "body"); const char *msgid; xep22->support = CHATSTATES_SUPPORT_OK; xep22->last_state_rcvd = ROSTER_EVENT_NONE;