comparison libpurple/protocols/jabber/pep.c @ 26791:80437c891f92

Publish only 'new' xmlns of avatars and delete old. Instead of publishing our avatar to both PEP nodes, publish only to the new and delete anything at the old. We still support receiving both/either. Backward compatibility is achieved through vcard-temp:x:update.
author Paul Aurich <paul@darkrain42.org>
date Mon, 27 Apr 2009 05:49:32 +0000
parents 242a8c97270b
children c26c6d25142d
comparison
equal deleted inserted replaced
26790:ca421152b5d4 26791:80437c891f92
110 110
111 /* discard items we don't have a handler for */ 111 /* discard items we don't have a handler for */
112 g_free(jid); 112 g_free(jid);
113 } 113 }
114 114
115 void jabber_pep_delete_node(JabberStream *js, const gchar *node)
116 {
117 JabberIq *iq;
118 xmlnode *pubsub, *del;
119
120 g_return_if_fail(node != NULL);
121 g_return_if_fail(js->pep);
122
123 iq = jabber_iq_new(js, JABBER_IQ_SET);
124
125 pubsub = xmlnode_new_child(iq->node, "pubsub");
126 xmlnode_set_namespace(pubsub, "http://jabber.org/protocol/pubsub#owner");
127
128 del = xmlnode_new_child(pubsub, "delete");
129 xmlnode_set_attrib(del, "node", node);
130
131 jabber_iq_send(iq);
132 }
133
115 void jabber_pep_publish(JabberStream *js, xmlnode *publish) { 134 void jabber_pep_publish(JabberStream *js, xmlnode *publish) {
116 JabberIq *iq; 135 JabberIq *iq;
117 xmlnode *pubsub; 136 xmlnode *pubsub;
118 137
119 if(js->pep != TRUE) { 138 if(js->pep != TRUE) {