changeset 125:1bf1a1233b88

[/trunk] Changeset 138 by mikael * Automatic subscription to our network presence updates. We should ask the user, of course, but at least it works...
author mikael
date Wed, 27 Apr 2005 19:48:57 +0000
parents 6d2122c003c4
children d3ee9abe9ca6
files mcabber/src/jabglue.c
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mcabber/src/jabglue.c	Tue Apr 26 20:05:14 2005 +0000
+++ b/mcabber/src/jabglue.c	Wed Apr 27 19:48:57 2005 +0000
@@ -293,7 +293,7 @@
   // because it allows to re-ask for notification.
 
   //x = jutil_presnew(JPACKET__SUBSCRIBE, jid, NULL);
-  x = jutil_presnew(JPACKET__SUBSCRIBE, jid, "online");
+  x = jutil_presnew(JPACKET__SUBSCRIBE, (char*)jid, "online");
   jab_send(jc, x);
   xmlnode_free(x);
 
@@ -731,6 +731,10 @@
           if (!isagent) {
             scr_LogPrint("<%s> wants to subscribe "
                          "to your network presence updates", from);
+            // FIXME we accept everybody...
+            x = jutil_presnew(JPACKET__SUBSCRIBED, from, 0);
+            jab_send(jc, x);
+            xmlnode_free(x);
           } else {
             x = jutil_presnew(JPACKET__SUBSCRIBED, from, 0);
             jab_send(jc, x);