diff options
author | James Booth <boothj5@gmail.com> | 2013-01-28 23:54:49 +0000 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2013-01-28 23:54:49 +0000 |
commit | a30474f9fcbc639505b21339f112572cac466eb4 (patch) | |
tree | 180dca201de697e6cace730a16338ab59eae31b4 | |
parent | bfe1d76e5fcc29bb9c2c13935e4dbb5ecf0731ff (diff) | |
download | profani-tty-a30474f9fcbc639505b21339f112572cac466eb4.tar.gz |
Changed adding iq handlers to take no args
-rw-r--r-- | src/xmpp.h | 2 | ||||
-rw-r--r-- | src/xmpp_conn.c | 2 | ||||
-rw-r--r-- | src/xmpp_iq.c | 4 |
3 files changed, 5 insertions, 3 deletions
diff --git a/src/xmpp.h b/src/xmpp.h index 7513608e..d1f88055 100644 --- a/src/xmpp.h +++ b/src/xmpp.h @@ -169,7 +169,7 @@ void jabber_conn_set_status(const char * const message); char* jabber_get_account_name(void); // iq functions -void iq_add_handlers(xmpp_conn_t * const conn, xmpp_ctx_t * const ctx); +void iq_add_handlers(void); // presence functions void presence_init(void); diff --git a/src/xmpp_conn.c b/src/xmpp_conn.c index 9bf94074..2d1a3076 100644 --- a/src/xmpp_conn.c +++ b/src/xmpp_conn.c @@ -665,7 +665,7 @@ _connection_handler(xmpp_conn_t * const conn, xmpp_handler_add(conn, _message_handler, NULL, STANZA_NAME_MESSAGE, NULL, ctx); xmpp_handler_add(conn, presence_handler, NULL, STANZA_NAME_PRESENCE, NULL, ctx); - iq_add_handlers(conn, ctx); + iq_add_handlers(); if (prefs_get_autoping() != 0) { int millis = prefs_get_autoping() * 1000; diff --git a/src/xmpp_iq.c b/src/xmpp_iq.c index fbef60ca..dae22ddb 100644 --- a/src/xmpp_iq.c +++ b/src/xmpp_iq.c @@ -49,8 +49,10 @@ static int _iq_handle_discoinfo_result(xmpp_conn_t * const conn, xmpp_stanza_t * const stanza, void * const userdata); void -iq_add_handlers(xmpp_conn_t * const conn, xmpp_ctx_t * const ctx) +iq_add_handlers(void) { + xmpp_conn_t * const conn = jabber_get_conn(); + xmpp_ctx_t * const ctx = jabber_get_ctx(); HANDLE(NULL, STANZA_TYPE_ERROR, _iq_handle_error); HANDLE(XMPP_NS_ROSTER, STANZA_TYPE_SET, _iq_handle_roster_set); HANDLE(XMPP_NS_ROSTER, STANZA_TYPE_RESULT, _iq_handle_roster_result); |