/soc/2013/ashmew2/filetransferX: 0e74fc4af67b: handling type='info'
Ashish Gupta
ashmew2 at gmail.com
Wed Aug 7 11:52:30 EDT 2013
Changeset: 0e74fc4af67bbe3f0b82ab19f86ebe621fedac66
Author: Ashish Gupta <ashmew2 at gmail.com>
Date: 2013-08-07 19:19 +0530
Branch: filetransferX
URL: https://hg.pidgin.im/soc/2013/ashmew2/filetransferX/rev/0e74fc4af67b
Description:
handling type='info'
diffstat:
libpurple/protocols/jabber/google/google_session.c | 14 +++++++++++++-
libpurple/protocols/jabber/google/google_session.h | 1 +
2 files changed, 14 insertions(+), 1 deletions(-)
diffs (40 lines):
diff --git a/libpurple/protocols/jabber/google/google_session.c b/libpurple/protocols/jabber/google/google_session.c
--- a/libpurple/protocols/jabber/google/google_session.c
+++ b/libpurple/protocols/jabber/google/google_session.c
@@ -786,6 +786,16 @@ FT XML:
return TRUE;
}
+void
+google_session_handle_info(JabberStream *js, GoogleSession *session, xmlnode *sess, const char *iq_id)
+{
+ JabberIq *iq;
+ iq = jabber_iq_new(js, JABBER_IQ_RESULT);
+ jabber_iq_set_id(iq, iq_id);
+ xmlnode_set_attrib(iq->node, "to", session->remote_jid);
+ jabber_iq_send(iq);
+}
+
static void
google_session_handle_candidates(JabberStream *js, GoogleSession *session, xmlnode *sess, const char *iq_id)
{
@@ -1355,7 +1365,9 @@ google_session_parse_iq(JabberStream *js
if (!strcmp(type, "initiate")) {
google_session_handle_initiate(js, session, sess, iq_id);
} else if (!strcmp(type, "accept")) {
- google_session_handle_accept(js, session, sess, iq_id);
+ google_session_handle_accept(js, session, sess, iq_id);
+ } else if (!strcmp(type, "info")) {
+ google_session_handle_info(js, session, sess, iq_id);
} else if (!strcmp(type, "reject")) {
google_session_handle_reject(js, session, sess);
} else if (!strcmp(type, "terminate")) {
diff --git a/libpurple/protocols/jabber/google/google_session.h b/libpurple/protocols/jabber/google/google_session.h
--- a/libpurple/protocols/jabber/google/google_session.h
+++ b/libpurple/protocols/jabber/google/google_session.h
@@ -57,4 +57,5 @@ void gtalk_xfer_send(PurpleConnection *g
void gtalk_xfer_init(PurpleXfer *xfer);
void gtalk_xfer_start(PurpleXfer *xfer);
void gtalk_xfer_send_transport_accept(JabberStream *js, GoogleSession *session, xmlnode *sess);
+void gtalk_xfer_send_accept(JabberStream *js, GoogleSession *session, xmlnode *sess);
#endif /* PURPLE_JABBER_GOOGLE_SESSION_H_ */
More information about the Commits
mailing list