[JDEV] Another jadc2s patch ... (sm reconnects)

Matthias Wimmer m at tthias.net
Sat Oct 11 17:26:41 CDT 2003


Hi!

Another patch to the jadc2s code I don't want to add myself to
repository as long as jabberd 1.4.3 is not released (even if jadc2s is
not part of it) ...

jadc2s/connect.c contains code to reconnect to the jabberd process if
the connection is lost. This starts at line 295 in this file. But it
didn't work as retries was always set to '0' which disabled retries.
This is because the wrong function was used to get the configuration
value. The following patch fixes this and enabled that reconnections can
be used.


Tot kijk
    Matthias


--- connect.c	2003-10-12 00:19:39.000000000 +0200
+++ connect-smretry.c	2003-10-12 00:19:58.000000000 +0200
@@ -293,7 +293,7 @@
 
         /* try to connect again */
         c2s = c->c2s;
-        retries = j_atoi(xhash_get(c2s->config, "sm.retries"), 5);
+        retries = j_atoi(config_get_one(c2s->config, "sm.retries", 0), 5);
         for (x = 0; x < retries; x++)
         {
             if (connect_new(c2s))

-- 
For kibibytes see:
http://www.iec.ch/online_news/etech/arch_2003/etech_0503/focus.htm
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://mail.jabber.org/pipermail/jdev/attachments/20031012/7d529172/attachment-0002.pgp>


More information about the JDev mailing list