]> code.citadel.org Git - citadel.git/commitdiff
Receiving Jabber messages now works correctly, with
authorArt Cancro <ajc@citadel.org>
Mon, 3 Dec 2007 05:02:16 +0000 (05:02 +0000)
committerArt Cancro <ajc@citadel.org>
Mon, 3 Dec 2007 05:02:16 +0000 (05:02 +0000)
the sender's JID mapped properly to the screen name.

citadel/modules/jabber/xmpp_messages.c

index d81e115d3be20241a5e4301c82ed779b3ef8207b..834b3edfbbe392221f3ad89e269e3c3b7ac868fa 100644 (file)
@@ -64,10 +64,9 @@ void jabber_output_incoming_messages(void) {
                CC->FirstExpressMessage = CC->FirstExpressMessage->next;
                end_critical_section(S_SESSION_TABLE);
 
-               /* FIXME we have to get the sender's email address.  This may involve tweaking
-                * the core IM module a bit.
-                */
-               cprintf("<message to=\"%s\" from=\"FIXME@example.org\" type=\"chat\">", XMPP->client_jid);
+               cprintf("<message to=\"%s\" from=\"%s\" type=\"chat\">",
+                       XMPP->client_jid,
+                       ptr->sender_email);
                if (ptr->text != NULL) {
                        striplt(ptr->text);
                        cprintf("<body>%s</body>", ptr->text);