diff libpurple/protocols/jabber/disco.c @ 26552:4f14455a86d2

propagate from branch 'im.pidgin.pidgin' (head f25348fdce436002d7d508f074aaa70fd9491f01) to branch 'im.pidgin.cpw.darkrain42.xmpp.iq-handlers' (head 33f84ea59a9e7afb3a03806268589ea49622326a)
author Paul Aurich <paul@darkrain42.org>
date Fri, 03 Apr 2009 16:45:38 +0000
parents cde07a2e4531 e23a74d7c97c
children 242a8c97270b bc7fac8e2f79 eea396f1583c b290c7b9fc73
line wrap: on
line diff
--- a/libpurple/protocols/jabber/disco.c	Fri Apr 03 02:43:22 2009 +0000
+++ b/libpurple/protocols/jabber/disco.c	Fri Apr 03 16:45:38 2009 +0000
@@ -28,6 +28,7 @@
 #include "iq.h"
 #include "disco.h"
 #include "jabber.h"
+#include "jingle/jingle.h"
 #include "presence.h"
 #include "roster.h"
 #include "pep.h"
@@ -143,6 +144,16 @@
 						SUPPORT_FEATURE(feat->namespace);
 				}
 			}
+#ifdef USE_VV
+		} else if (node && !strcmp(node, CAPS0115_NODE "#voice-v1")) {
+			SUPPORT_FEATURE("http://www.google.com/xmpp/protocol/session");
+			SUPPORT_FEATURE("http://www.google.com/xmpp/protocol/voice/v1");
+			SUPPORT_FEATURE(JINGLE);
+			SUPPORT_FEATURE(JINGLE_APP_RTP_SUPPORT_AUDIO);
+			SUPPORT_FEATURE(JINGLE_APP_RTP_SUPPORT_VIDEO);
+			SUPPORT_FEATURE(JINGLE_TRANSPORT_RAWUDP);
+			SUPPORT_FEATURE(JINGLE_TRANSPORT_ICEUDP);
+#endif
 		} else {
 			const char *ext = NULL;
 			unsigned pos;
@@ -430,6 +441,11 @@
 		if (!strcmp(name, "Google Talk")) {
 			purple_debug_info("jabber", "Google Talk!\n");
 			js->googletalk = TRUE;
+
+			/* autodiscover stun and relays */
+			jabber_google_send_jingle_info(js);
+		} else {
+			/* TODO: add external service discovery here... */
 		}
 	}