cpw.darkrain42.obsolete: 2348ff22: disapproval of revision 'a383ad6a4ae7e98...
darkrain42 at pidgin.im
darkrain42 at pidgin.im
Sun Jul 12 01:55:44 EDT 2009
-----------------------------------------------------------------
Revision: 2348ff22f0ff3453774b8b25b36238465580c609
Ancestor: a383ad6a4ae7e98bbcb32b4193531ccf960eb2bb
Author: darkrain42 at pidgin.im
Date: 2009-07-12T05:42:40
Branch: im.pidgin.cpw.darkrain42.obsolete
URL: http://d.pidgin.im/viewmtn/revision/info/2348ff22f0ff3453774b8b25b36238465580c609
Modified files:
libpurple/protocols/jabber/message.c
libpurple/protocols/jabber/presence.c
ChangeLog:
disapproval of revision 'a383ad6a4ae7e98bbcb32b4193531ccf960eb2bb'
Legacy Delayed Delivery is still too widely deployed.
-------------- next part --------------
============================================================
--- libpurple/protocols/jabber/message.c 005fac383641fa420d98c4c8b2f0c43e25525d98
+++ libpurple/protocols/jabber/message.c 82d8a9d31758302bec709fea15b7447bb65ffc16
@@ -740,7 +740,12 @@ void jabber_message_parse(JabberStream *
if(timestamp)
jm->sent = purple_str_to_time(timestamp, TRUE, NULL, NULL, NULL);
} else if(!strcmp(child->name, "x")) {
- if(!strcmp(xmlns, "jabber:x:conference") &&
+ if(!strcmp(xmlns, "jabber:x:delay")) {
+ const char *timestamp = xmlnode_get_attrib(child, "stamp");
+ jm->delayed = TRUE;
+ if(timestamp)
+ jm->sent = purple_str_to_time(timestamp, TRUE, NULL, NULL, NULL);
+ } else if(!strcmp(xmlns, "jabber:x:conference") &&
jm->type != JABBER_MESSAGE_GROUPCHAT_INVITE &&
jm->type != JABBER_MESSAGE_ERROR) {
const char *jid = xmlnode_get_attrib(child, "jid");
============================================================
--- libpurple/protocols/jabber/presence.c cdb99b32cbba2a31ca1c89c5b0b28188167de62c
+++ libpurple/protocols/jabber/presence.c 5e9b0d51856feb3b541a226f70c7b7d83cd52c98
@@ -576,7 +576,7 @@ void jabber_presence_parse(JabberStream
/* The rest of the cases used to check xmlns individually. */
continue;
} else if(!strcmp(y->name, "delay") && !strcmp(xmlns, "urn:xmpp:delay")) {
- /* XXX: compare the time. urn:xmpp:delay can happen on presence packets that aren't really and truly delayed */
+ /* XXX: compare the time. jabber:x:delay can happen on presence packets that aren't really and truly delayed */
delayed = TRUE;
stamp = xmlnode_get_attrib(y, "stamp");
} else if(!strcmp(y->name, "c") && !strcmp(xmlns, "http://jabber.org/protocol/caps")) {
@@ -584,7 +584,11 @@ void jabber_presence_parse(JabberStream
} else if (g_str_equal(y->name, "nick") && g_str_equal(xmlns, "http://jabber.org/protocol/nick")) {
nickname = xmlnode_get_data(y);
} else if(!strcmp(y->name, "x")) {
- if(!strcmp(xmlns, "http://jabber.org/protocol/muc#user")) {
+ if(!strcmp(xmlns, "jabber:x:delay")) {
+ /* XXX: compare the time. jabber:x:delay can happen on presence packets that aren't really and truly delayed */
+ delayed = TRUE;
+ stamp = xmlnode_get_attrib(y, "stamp");
+ } else if(!strcmp(xmlns, "http://jabber.org/protocol/muc#user")) {
xmlnode *z;
muc = TRUE;
More information about the Commits
mailing list