libpurple/protocols/jabber/disco.c

branch
string-comparison-r2
changeset 38256
035f00c4fd87
parent 31680
d3902c687705
child 38258
9a6551eba09c
equal deleted inserted replaced
38239:f76c1aa92c07 38256:035f00c4fd87
121 query = xmlnode_get_child(iq->node, "query"); 121 query = xmlnode_get_child(iq->node, "query");
122 122
123 if(node) 123 if(node)
124 xmlnode_set_attrib(query, "node", node); 124 xmlnode_set_attrib(query, "node", node);
125 125
126 if(!node || g_str_equal(node, node_uri)) { 126 if(!node || purple_strequal(node, node_uri)) {
127 GList *features, *identities; 127 GList *features, *identities;
128 for(identities = jabber_identities; identities; identities = identities->next) { 128 for(identities = jabber_identities; identities; identities = identities->next) {
129 JabberIdentity *ident = (JabberIdentity*)identities->data; 129 JabberIdentity *ident = (JabberIdentity*)identities->data;
130 identity = xmlnode_new_child(query, "identity"); 130 identity = xmlnode_new_child(query, "identity");
131 xmlnode_set_attrib(identity, "category", ident->category); 131 xmlnode_set_attrib(identity, "category", ident->category);
141 feature = xmlnode_new_child(query, "feature"); 141 feature = xmlnode_new_child(query, "feature");
142 xmlnode_set_attrib(feature, "var", feat->namespace); 142 xmlnode_set_attrib(feature, "var", feat->namespace);
143 } 143 }
144 } 144 }
145 #ifdef USE_VV 145 #ifdef USE_VV
146 } else if (g_str_equal(node, CAPS0115_NODE "#" "voice-v1")) { 146 } else if (purple_strequal(node, CAPS0115_NODE "#" "voice-v1")) {
147 /* 147 /*
148 * HUGE HACK! We advertise this ext (see jabber_presence_create_js 148 * HUGE HACK! We advertise this ext (see jabber_presence_create_js
149 * where we add <c/> to the <presence/>) for the Google Talk 149 * where we add <c/> to the <presence/>) for the Google Talk
150 * clients that don't actually check disco#info features. 150 * clients that don't actually check disco#info features.
151 * 151 *
153 * node='http://mail.google.com/xmpp/client/caps', ver='1.1' 153 * node='http://mail.google.com/xmpp/client/caps', ver='1.1'
154 * advertises as 'voice-v1'. 154 * advertises as 'voice-v1'.
155 */ 155 */
156 xmlnode *feature = xmlnode_new_child(query, "feature"); 156 xmlnode *feature = xmlnode_new_child(query, "feature");
157 xmlnode_set_attrib(feature, "var", NS_GOOGLE_VOICE); 157 xmlnode_set_attrib(feature, "var", NS_GOOGLE_VOICE);
158 } else if (g_str_equal(node, CAPS0115_NODE "#" "video-v1")) { 158 } else if (purple_strequal(node, CAPS0115_NODE "#" "video-v1")) {
159 /* 159 /*
160 * HUGE HACK! We advertise this ext (see jabber_presence_create_js 160 * HUGE HACK! We advertise this ext (see jabber_presence_create_js
161 * where we add <c/> to the <presence/>) for the Google Talk 161 * where we add <c/> to the <presence/>) for the Google Talk
162 * clients that don't actually check disco#info features. 162 * clients that don't actually check disco#info features.
163 * 163 *
165 * node='http://mail.google.com/xmpp/client/caps', ver='1.1' 165 * node='http://mail.google.com/xmpp/client/caps', ver='1.1'
166 * advertises as 'video-v1'. 166 * advertises as 'video-v1'.
167 */ 167 */
168 xmlnode *feature = xmlnode_new_child(query, "feature"); 168 xmlnode *feature = xmlnode_new_child(query, "feature");
169 xmlnode_set_attrib(feature, "var", NS_GOOGLE_VIDEO); 169 xmlnode_set_attrib(feature, "var", NS_GOOGLE_VIDEO);
170 } else if (g_str_equal(node, CAPS0115_NODE "#" "camera-v1")) { 170 } else if (purple_strequal(node, CAPS0115_NODE "#" "camera-v1")) {
171 /* 171 /*
172 * HUGE HACK! We advertise this ext (see jabber_presence_create_js 172 * HUGE HACK! We advertise this ext (see jabber_presence_create_js
173 * where we add <c/> to the <presence/>) for the Google Talk 173 * where we add <c/> to the <presence/>) for the Google Talk
174 * clients that don't actually check disco#info features. 174 * clients that don't actually check disco#info features.
175 * 175 *

mercurial