diff options
-rw-r--r-- | gabble/capabilities.h | 2 | ||||
-rw-r--r-- | src/jingle-media-rtp.c | 4 | ||||
-rw-r--r-- | src/presence-cache.c | 12 |
3 files changed, 17 insertions, 1 deletions
diff --git a/gabble/capabilities.h b/gabble/capabilities.h index 2e3175529..81c8c2546 100644 --- a/gabble/capabilities.h +++ b/gabble/capabilities.h @@ -33,6 +33,8 @@ #define QUIRK_OMITS_CONTENT_CREATORS "\x07omits-content-creators" /* The Google Webmail client doesn't support some features */ #define QUIRK_GOOGLE_WEBMAIL_CLIENT "\x07google-webmail-client" +/* The Android GTalk client needs a quirk for component names */ +#define QUIRK_ANDROID_GTALK_CLIENT "\x07android-gtalk-client" /* Some useful capability sets for Jingle etc. */ const GabbleCapabilitySet *gabble_capabilities_get_legacy (void); diff --git a/src/jingle-media-rtp.c b/src/jingle-media-rtp.c index 9a120078c..45a14191a 100644 --- a/src/jingle-media-rtp.c +++ b/src/jingle-media-rtp.c @@ -337,7 +337,9 @@ static void transport_created (GabbleJingleContent *content, if (priv->media_type == JINGLE_MEDIA_TYPE_VIDEO && (JINGLE_IS_GOOGLE_DIALECT (dialect) || gabble_jingle_session_peer_has_cap (content->session, - QUIRK_GOOGLE_WEBMAIL_CLIENT))) + QUIRK_GOOGLE_WEBMAIL_CLIENT) || + gabble_jingle_session_peer_has_cap (content->session, + QUIRK_ANDROID_GTALK_CLIENT))) { jingle_transport_google_set_component_name (gtrans, "video_rtp", 1); jingle_transport_google_set_component_name (gtrans, "video_rtcp", 2); diff --git a/src/presence-cache.c b/src/presence-cache.c index b5a0dab8d..31a301215 100644 --- a/src/presence-cache.c +++ b/src/presence-cache.c @@ -1042,6 +1042,18 @@ _parse_node (GabblePresence *presence, gabble_presence_set_capabilities (presence, resource, cap_set, NULL, serial); gabble_capability_set_free (cap_set); } + + if (!tp_strdiff (node, "http://www.android.com/gtalk/client/caps") || + !tp_strdiff (node, "http://www.android.com/gtalk/client/caps2")) + { + GabbleCapabilitySet *cap_set = gabble_capability_set_new (); + + DEBUG ("Client is Android GTalk Client"); + + gabble_capability_set_add (cap_set, QUIRK_ANDROID_GTALK_CLIENT); + gabble_presence_set_capabilities (presence, resource, cap_set, NULL, serial); + gabble_capability_set_free (cap_set); + } } |