keepalived-1.1.15 v1.1.15
authorAlexandre Cassen <acassen@freebox.fr>
Tue, 18 Sep 2007 09:43:49 +0000 (11:43 +0200)
committerAlexandre Cassen <acassen@freebox.fr>
Mon, 28 Sep 2009 08:59:01 +0000 (10:59 +0200)
* keepalived-1.1.15 released.
* Matthias Saou, <matthias at rpmforge.net> fixed genhash
  Makefile for man page installation.
* Casey Zacek, <keepalived at bogleg.org> provided a patch
  to check_http to remove buffer minimization while processing
  stream. It appears some webserver cause healthchecker crash.
* Chris Marchesi, <chris.marchesi at canadawebhosting.com> provided
  a patch for better handling of SSL handshake errors.
* Shinji Tanaka, <stanaka at hatena.ne.jp> fixed parser "include"
  directive to support declaration inside configuration directives,
  like including file inside vrrp_instance declaration.
* Andreas Kotes, <count at flatline.de> fixed HTTP healthchecker
  while handling MD5SUM result. It appears checker never removed
  realserver on MD5SUM mismatch !!! whats that crap.
* VRRP : Willy Tarreau, <w at 1wt.eu> fixed a missing notifications
  upon transition from fault to backup.
* VRRP : Add support to route metric in virtual_routes definition.

94 files changed:
ChangeLog
VERSION
doc/keepalived.conf.SYNOPSIS
genhash/Makefile.in
keepalived.spec.in
keepalived/check/check_api.c
keepalived/check/check_daemon.c
keepalived/check/check_data.c
keepalived/check/check_http.c
keepalived/check/check_misc.c
keepalived/check/check_parser.c
keepalived/check/check_smtp.c
keepalived/check/check_ssl.c
keepalived/check/check_tcp.c
keepalived/check/ipfwwrapper.c
keepalived/check/ipvswrapper.c
keepalived/check/ipwrapper.c
keepalived/core/daemon.c
keepalived/core/global_data.c
keepalived/core/global_parser.c
keepalived/core/layer4.c
keepalived/core/main.c
keepalived/core/pidfile.c
keepalived/core/smtp.c
keepalived/include/check_api.h
keepalived/include/check_daemon.h
keepalived/include/check_data.h
keepalived/include/check_http.h
keepalived/include/check_misc.h
keepalived/include/check_parser.h
keepalived/include/check_smtp.h
keepalived/include/check_ssl.h
keepalived/include/check_tcp.h
keepalived/include/config.h.in
keepalived/include/daemon.h
keepalived/include/global_data.h
keepalived/include/global_parser.h
keepalived/include/ipfwwrapper.h
keepalived/include/ipvswrapper.h
keepalived/include/ipwrapper.h
keepalived/include/layer4.h
keepalived/include/main.h
keepalived/include/pidfile.h
keepalived/include/smtp.h
keepalived/include/vrrp.h
keepalived/include/vrrp_arp.h
keepalived/include/vrrp_daemon.h
keepalived/include/vrrp_data.h
keepalived/include/vrrp_if.h
keepalived/include/vrrp_index.h
keepalived/include/vrrp_ipaddress.h
keepalived/include/vrrp_iproute.h
keepalived/include/vrrp_ipsecah.h
keepalived/include/vrrp_netlink.h
keepalived/include/vrrp_notify.h
keepalived/include/vrrp_parser.h
keepalived/include/vrrp_scheduler.h
keepalived/include/vrrp_sync.h
keepalived/include/vrrp_track.h
keepalived/vrrp/vrrp.c
keepalived/vrrp/vrrp_arp.c
keepalived/vrrp/vrrp_daemon.c
keepalived/vrrp/vrrp_data.c
keepalived/vrrp/vrrp_if.c
keepalived/vrrp/vrrp_index.c
keepalived/vrrp/vrrp_ipaddress.c
keepalived/vrrp/vrrp_iproute.c
keepalived/vrrp/vrrp_ipsecah.c
keepalived/vrrp/vrrp_netlink.c
keepalived/vrrp/vrrp_notify.c
keepalived/vrrp/vrrp_parser.c
keepalived/vrrp/vrrp_scheduler.c
keepalived/vrrp/vrrp_sync.c
keepalived/vrrp/vrrp_track.c
lib/html.c
lib/html.h
lib/list.c
lib/list.h
lib/memory.c
lib/memory.h
lib/notify.c
lib/notify.h
lib/parser.c
lib/parser.h
lib/scheduler.c
lib/scheduler.h
lib/signals.c
lib/signals.h
lib/timer.c
lib/timer.h
lib/utils.c
lib/utils.h
lib/vector.c
lib/vector.h

index 9ba7a9d..25c3206 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,22 @@
+2007-09-15  Alexandre Cassen  <acassen@linux-vs.org>
+       * keepalived-1.1.15 released.
+       * Matthias Saou, <matthias at rpmforge.net> fixed genhash
+         Makefile for man page installation.
+       * Casey Zacek, <keepalived at bogleg.org> provided a patch
+         to check_http to remove buffer minimization while processing
+         stream. It appears some webserver cause healthchecker crash.
+       * Chris Marchesi, <chris.marchesi at canadawebhosting.com> provided
+         a patch for better handling of SSL handshake errors.
+       * Shinji Tanaka, <stanaka at hatena.ne.jp> fixed parser "include" 
+         directive to support declaration inside configuration directives,
+         like including file inside vrrp_instance declaration.
+       * Andreas Kotes, <count at flatline.de> fixed HTTP healthchecker
+         while handling MD5SUM result. It appears checker never removed
+         realserver on MD5SUM mismatch !!! whats that crap.
+       * VRRP : Willy Tarreau, <w at 1wt.eu> fixed a missing notifications
+         upon transition from fault to backup.
+       * VRRP : Add support to route metric in virtual_routes definition.
+       
 2007-09-13  Alexandre Cassen  <acassen@linux-vs.org>
        * keepalived-1.1.14 released.
        * Shinji Tanaka, <stanaka at hatena.ne.jp> extended parsing
diff --git a/VERSION b/VERSION
index e9bc149..645377e 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-1.1.14
+1.1.15
index e33747a..6f9804c 100644 (file)
@@ -175,8 +175,8 @@ vrrp_instance <STRING> {            # VRRP instance declaration
         ...
     }
     virtual_routes {                   # VRRP virtual routes
-       src <IP ADDRESS> [to] <IP ADDRESS>/<MASK> via|gw <IP ADDRESS> dev <STRING> scope <SCOPE> table <TABLE-ID> # to is optional
-       src <IP ADDRESS> [to] <IP ADDRESS>/<MASK> via|gw <IP ADDRESS> dev <STRING> scope <SCOPE> table <TABLE-ID> # to is optional
+       src <IP ADDRESS> [to] <IP ADDRESS>/<MASK> via|gw <IP ADDRESS> dev <STRING> scope <SCOPE> table <TABLE-ID> metric <METRIC> # to is optional
+       src <IP ADDRESS> [to] <IP ADDRESS>/<MASK> via|gw <IP ADDRESS> dev <STRING> scope <SCOPE> table <TABLE-ID> metric <METRIC> # to is optional
         ...
     }
     nopreempt                                  # Override VRRP RFC preemption default
@@ -202,6 +202,8 @@ LABEL is optional and creates a name for the alias. For compatibility with
 "ifconfig", it should be of the form <realdev>:<anytext>, for example
 eth0:1 for an alias on eth0.
 
+METRIC is optional and specify a route priority.
+
 When a weight is specified in track_interface, instead of setting the vrrp
 instance to the FAULT state in case of failure, its priority will be
 increased by the weight when the interface is up (for positive weights),
index 6c9921e..9e3bae4 100644 (file)
@@ -39,13 +39,13 @@ distclean: clean
 
 uninstall:
        rm -f $(DESTDIR)$(bindir)/$(EXEC)
-       rm -f $(DESTDIR)$(mandir)/man/man1/genhash.1
+       rm -f $(DESTDIR)$(mandir)/man1/genhash.1
 
 install:
        install -d $(DESTDIR)$(bindir)
        install -m 755 $(BIN)/$(EXEC) $(DESTDIR)$(bindir)/
-       install -d $(DESTDIR)$(mandir)/man/man1
-       install -m 644 ../doc/man/man1/genhash.1 $(DESTDIR)$(mandir)/man/man1
+       install -d $(DESTDIR)$(mandir)/man1
+       install -m 644 ../doc/man/man1/genhash.1 $(DESTDIR)$(mandir)/man1
 
 mrproper: clean distclean
        rm -f config.*
index 1dbbdd6..6b4f287 100644 (file)
@@ -6,7 +6,7 @@
 
 Summary: HA monitor built upon LVS, VRRP and services poller
 Name: keepalived
-Version: 1.1.13
+Version: 1.1.15
 Release: 5
 License: GPL
 Group: Applications/System
index 8f2cf12..57ebe4b 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Checkers registration.
  *
- * Version:     $Id: check_api.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_api.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 18be7b2..e1daecd 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Healthcheckrs child process handling.
  *
- * Version:     $Id: check_daemon.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_daemon.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index b0649c5..dfd28f9 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Healthcheckers dynamic data structure definition.
  *
- * Version:     $Id: check_data.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_data.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index bbea456..c27b6a8 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        WEB CHECK. Common HTTP/SSL checker primitives.
  *
- * Version:     $Id: check_http.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_http.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
@@ -471,6 +471,13 @@ http_handle_response(thread * thread_obj, unsigned char digest[16]
                                       inet_ntop2(CHECKER_RIP(checker_obj)),
                                       ntohs(addr_port), fetched_url->path,
                                       digest_tmp);
+                               smtp_alert(checker_obj->rs, NULL, NULL,
+                                          "DOWN",
+                                          "=> CHECK failed on service"
+                                          " : HTTP MD5SUM mismatch <=");
+                               update_svr_checker_state(DOWN, checker_obj->id
+                                                            , checker_obj->vs
+                                                            , checker_obj->rs);
                        } else {
                                DBG("MD5SUM to [%s:%d] url(%d) = [%s].",
                                    inet_ntop2(CHECKER_RIP(checker_obj))
@@ -515,13 +522,6 @@ http_process_response(REQ *req, int r)
                                r = 0;
                        }
                        req->len = r;
-               } else {
-                       /* minimize buffer using no 2*CR/LF found yet */
-                       if (req->len > 4) {
-                               memmove(req->buffer,
-                                       req->buffer + req->len - 4, 4);
-                               req->len = 4;
-                       }
                }
        } else if (req->len) {
                MD5_Update(&req->context, req->buffer,
@@ -830,6 +830,23 @@ http_check_thread(thread * thread_obj)
                                        ssl_printerr(SSL_get_error
                                                     (req->ssl, ret));
 #endif
+                               if ((http_get_check->proto == PROTO_SSL) &&
+                                   (svr_checker_up(checker_obj->id, checker_obj->rs))) {
+                                       syslog(LOG_INFO, "SSL handshake/communication error"
+                                                        " connecting to server"
+                                                        " (openssl errno: %d) [%s:%d]."
+                                                      , SSL_get_error (http_arg_obj->req->ssl, ret)
+                                                      , inet_ntop2(CHECKER_RIP(checker_obj))
+                                                      , ntohs(addr_port));
+                                       smtp_alert(checker_obj->rs, NULL, NULL,
+                                                  "DOWN",
+                                                  "=> CHECK failed on service"
+                                                  " : SSL connection error <=");
+                                       update_svr_checker_state(DOWN, checker_obj->id
+                                                                , checker_obj->vs
+                                                                , checker_obj->rs);
+                               }
+
                                return epilog(thread_obj, 1, 0, 0);
                        }
                }
index f936fc7..f406d26 100644 (file)
@@ -6,7 +6,7 @@
  * Part:        MISC CHECK. Perform a system call to run an extra
  *              system prog or script.
  *
- * Version:     $Id: check_misc.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_misc.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Eric Jarman, <ehj38230@cmsu2.cmsu.edu>
index 57e6a58..5ce6fcc 100644 (file)
@@ -7,7 +7,7 @@
  *              data structure representation the conf file representing
  *              the loadbalanced server pool.
  *  
- * Version:     $Id: check_parser.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_parser.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 79f7aab..ab317d8 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        SMTP CHECK. Check an SMTP-server.
  *
- * Version:     $Id: check_smtp.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_smtp.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Jeremy Rumpf, <jrumpf@heavyload.net>
  *              Alexandre Cassen, <acassen@linux-vs.org>
index 890d864..10ab7ca 100644 (file)
@@ -7,7 +7,7 @@
  *              url, compute a MD5 over this result and match it to the
  *              expected value.
  *
- * Version:     $Id: check_ssl.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_ssl.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
index a469311..0515587 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        TCP checker.
  *
- * Version:     $Id: check_tcp.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_tcp.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 7e27dfd..8b47c17 100644 (file)
@@ -7,7 +7,7 @@
  *              library to add/remove server MASQ rules to the kernel 
  *              firewall framework.
  *
- * Version:     $Id: ipfwwrapper.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipfwwrapper.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 8d72bcf..5992ead 100644 (file)
@@ -6,7 +6,7 @@
  * Part:        IPVS Kernel wrapper. Use setsockopt call to add/remove
  *              server to/from the loadbalanced server pool.
  *  
- * Version:     $Id: ipvswrapper.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipvswrapper.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index f7625c4..c351ce4 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Manipulation functions for IPVS & IPFW wrappers.
  *
- * Version:     $Id: ipwrapper.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipwrapper.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 00e85e6..c325634 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Main program structure.
  *
- * Version:     $Id: main.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: main.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index a8e3248..21c9f42 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Dynamic data structure definition.
  *
- * Version:     $Id: global_data.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: global_data.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index be3449e..3398fac 100644 (file)
@@ -7,7 +7,7 @@
  *              data structure representation the conf file representing
  *              the loadbalanced server pool.
  *  
- * Version:     $Id: global_parser.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: global_parser.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 1832419..7c01eb2 100644 (file)
@@ -6,7 +6,7 @@
  * Part:        Layer4 checkers handling. Register worker threads &
  *              upper layer checkers.
  *
- * Version:     $Id: layer4.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: layer4.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 1d78b82..01600de 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Main program structure.
  *
- * Version:     $Id: main.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: main.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 80c0c10..dd039ed 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        pidfile utility.
  *
- * Version:     $Id: pidfile.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: pidfile.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 7fbb197..fcf2684 100644 (file)
@@ -7,7 +7,7 @@
  *              using the smtp protocol according to the RFC 821. A non blocking
  *              timeouted connection is used to handle smtp protocol.
  *
- * Version:     $Id: smtp.c,v 1.1.13 2006/10/11 05:22:13 acassen Exp $
+ * Version:     $Id: smtp.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 43a3fbd..d1a2590 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Checkers arguments structures definitions.
  *
- * Version:     $Id: check_api.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_api.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 599be66..fbafc43 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_daemon.c include file.
  * 
- * Version:     $Id: check_daemon.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_daemon.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index f61b430..b6cc201 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Healthcheckers dynamic data structure definition.
  *
- * Version:     $Id: check_data.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_data.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 0279acc..20ae21b 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_http.c include file.
  *
- * Version:     $Id: check_http.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_http.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
index 0561c25..56ff7fd 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_misc.c include file.
  *
- * Version:     $Id: check_misc.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_misc.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              Eric Jarman, <ehj38230@cmsu2.cmsu.edu>
index 001c8fb..e697694 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        check_parser.c include file.
  *  
- * Version:     $Id: check_parser.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_parser.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 59da3ad..3859d06 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_smtp.c include file.
  *
- * Version:     $Id: check_smtp.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_smtp.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              Jeremy Rumpf, <jrumpf@heavyload.net>
index 389de1a..76df8cb 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_http.c include file.
  *
- * Version:     $Id: check_http.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_http.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
index fbc7fcd..22c63c7 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        check_tcp.c include file.
  *
- * Version:     $Id: check_tcp.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: check_tcp.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index e6264f8..7b783b8 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Configuration include file.
  *
- * Version:     $Id: config.h.in,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: config.h.in,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Jacob Rief, <jacob.rief@tiscover.com>
  *
index 339da47..f1d7755 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Daemon process handling.
  *
- * Version:     $Id: daemon.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: daemon.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 301def7..141a2a2 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Dynamic data structure definition.
  *
- * Version:     $Id: global_data.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: global_data.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index e90c5d9..04eedff 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        vrrp_parser.c include file.
  *  
- * Version:     $Id: global_parser.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: global_parser.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index e3da95d..aa240b8 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        ipfwwrapper.c include file.
  *
- * Version:     $Id: ipfwwrapper.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipfwwrapper.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ecf8028..77d9085 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        ipvswrapper.c include file.
  *
- * Version:     $Id: ipvswrapper.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipvswrapper.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 75f224a..3accba5 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        ipwrapper.c include file.
  *
- * Version:     $Id: ipwrapper.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: ipwrapper.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 06fa0f1..9e14e99 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        layer4.c include file.
  *
- * Version:     $Id: layer4.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: layer4.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 3c29046..f205f28 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Main program include file.
  *
- * Version:     $Id: main.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: main.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 5a9fbc3..f5e7296 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        pidfile.c include file.
  *
- * Version:     $Id: pidfile.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: pidfile.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 7464dca..31fe9be 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        smtp.c include file.
  *
- * Version:     $Id: smtp.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: smtp.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ea2b506..7edee4a 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Part:        vrrp.c program include file.
  *
- * Version:     $Id: vrrp.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ef57dc2..74aab26 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_arp.c include file.
  *
- * Version:     $Id: vrrp_arp.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_arp.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index d4bb117..832d178 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_daemon.c include file.
  * 
- * Version:     $Id: vrrp_daemon.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_daemon.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index f22e3f6..81dc8de 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Dynamic data structure definition.
  *
- * Version:     $Id: vrrp_data.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_data.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 8c71c85..a2b7b18 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_if.c include file.
  *
- * Version:     $Id: vrrp_if.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_if.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index d3e159c..8efa577 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_index.c include file.
  *
- * Version:     $Id: vrrp_index.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_index.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index c8a5d55..a287b15 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_ipaddress.c include file.
  *
- * Version:     $Id: vrrp_ipaddress.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_ipaddress.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 5de93db..932fc0c 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_iproute.c include file.
  *
- * Version:     $Id: vrrp_iproute.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_iproute.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
 
 /* types definition */
 typedef struct _ip_route {
-       uint32_t dst;   /* RTA_DST */
+       uint32_t dst;           /* RTA_DST */
        uint8_t dmask;
-       uint32_t gw;    /* RTA_GATEWAY */
-       uint32_t src;   /* RTA_PREFSRC */
-       int index;      /* RTA_OIF */
+       uint32_t gw;            /* RTA_GATEWAY */
+       uint32_t src;           /* RTA_PREFSRC */
+       uint32_t metric;        /* RTA_PRIORITY */
+       int index;              /* RTA_OIF */
        int scope;
        int table;
        int set;
index 5d14ee7..711ca17 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_ipsecah.c include file.
  * 
- * Version:     $Id: vrrp_ipsecah.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_ipsecah.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 77ab5d3..86a0b30 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_netlink.c include file.
  *
- * Version:     $Id: vrrp_netlink.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_netlink.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 58c72e7..1c11290 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Part:        vrrp_notify.c include file.
  *
- * Version:     $Id: vrrp_notify.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_notify.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index f3a748f..2b7a471 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        vrrp_parser.c include file.
  *  
- * Version:     $Id: vrrp_parser.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_parser.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 863db81..305f9d5 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_scheduler.c include file.
  * 
- * Version:     $Id: vrrp_scheduler.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_scheduler.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index ac04411..981fe51 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_sync.c include file.
  * 
- * Version:     $Id: vrrp_sync.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_sync.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 691d3cb..c8168c1 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        vrrp_track.c include file.
  *
- * Version:     $Id: vrrp_track.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_track.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 8ce7336..01e2eb7 100644 (file)
@@ -8,7 +8,7 @@
  *              master fails, a backup server takes over.
  *              The original implementation has been made by jerome etienne.
  *
- * Version:     $Id: vrrp.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index a64f481..8e9d53b 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        ARP primitives.
  *
- * Version:     $Id: vrrp_arp.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_arp.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index b83d66a..540a5e0 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        VRRP child process handling.
  *
- * Version:     $Id: vrrp_daemon.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_daemon.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index f0caa31..3e756d7 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Dynamic data structure definition.
  *
- * Version:     $Id: vrrp_data.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_data.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 826dbf3..ee3ae1b 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Interfaces manipulation.
  *
- * Version:     $Id: vrrp_if.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_if.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 7eaaf57..062c6ae 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        VRRP instance index table.
  *
- * Version:     $Id: vrrp_index.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_index.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 002b4ba..c61dc1c 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        NETLINK IPv4 address manipulation.
  *
- * Version:     $Id: vrrp_ipaddress.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_ipaddress.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ca44cb1..f1d6e3d 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        NETLINK IPv4 routes manipulation.
  *
- * Version:     $Id: vrrp_iproute.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_iproute.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
@@ -64,6 +64,8 @@ netlink_route_ipv4(ip_route *iproute, int cmd)
                addattr32(&req.n, sizeof(req), RTA_OIF, iproute->index);
        if (iproute->src)
                addattr_l(&req.n, sizeof(req), RTA_PREFSRC, &iproute->src, 4);
+       if (iproute->metric)
+               addattr32(&req.n, sizeof(req), RTA_PRIORITY, iproute->metric);
 
        if (netlink_talk(&nl_cmd, &req.n) < 0)
                status = -1;
@@ -103,7 +105,7 @@ void
 dump_iproute(void *rt_data_obj)
 {
        ip_route *route = rt_data_obj;
-       char *log_msg = MALLOC(100);
+       char *log_msg = MALLOC(150);
        char *tmp = MALLOC(30);
 
        if (route->dst) {
@@ -132,6 +134,10 @@ dump_iproute(void *rt_data_obj)
                         netlink_scope_n2a(route->scope));
                strncat(log_msg, tmp, 30);
        }
+       if (route->metric) {
+               snprintf(tmp, 30, " metric %d", route->metric);
+               strncat(log_msg, tmp, 30);
+       }
 
        syslog(LOG_INFO, "     %s", log_msg);
 
@@ -170,6 +176,8 @@ alloc_route(list rt_list, vector strvec)
                        new->index = IF_INDEX(ifp);
                } else if (!strcmp(str, "table")) {
                        new->table = atoi(VECTOR_SLOT(strvec, ++i));
+               } else if (!strcmp(str, "metric")) {
+                       new->metric = atoi(VECTOR_SLOT(strvec, ++i));
                } else if (!strcmp(str, "scope")) {
                        new->scope = netlink_scope_a2n(VECTOR_SLOT(strvec, ++i));
                } else {
index f06a9ad..2caa575 100644 (file)
@@ -7,7 +7,7 @@
  *              authentication data encryption using HMAC MD5 according to
  *              RFCs 2085 & 2104.
  *
- * Version:     $Id: vrrp_ipsecah.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_ipsecah.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index f68fdf4..d7375ca 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        NETLINK kernel command channel.
  *
- * Version:     $Id: vrrp_netlink.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_netlink.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 404fc01..ada7efe 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        VRRP state transition notification scripts handling.
  *
- * Version:     $Id: vrrp_notify.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_notify.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 8cdd796..3131c3c 100644 (file)
@@ -7,7 +7,7 @@
  *              data structure representation the conf file representing
  *              the loadbalanced server pool.
  *  
- * Version:     $Id: vrrp_parser.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_parser.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 8c89d63..003dd57 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Sheduling framework for vrrp code.
  *
- * Version:     $Id: vrrp_scheduler.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_scheduler.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
@@ -647,8 +647,8 @@ vrrp_goto_master(vrrp_rt * vrrp)
                syslog(LOG_INFO, "VRRP_Instance(%s) Now in FAULT state",
                       vrrp->iname);
                vrrp->state = VRRP_STATE_FAULT;
-               vrrp->ms_down_timer =
-                   3 * vrrp->adver_int + VRRP_TIMER_SKEW(vrrp);
+               vrrp->ms_down_timer = 3 * vrrp->adver_int + VRRP_TIMER_SKEW(vrrp);
+               notify_instance_exec(vrrp, VRRP_STATE_FAULT);
        } else {
                /* If becoming MASTER in IPSEC AH AUTH, we reset the anti-replay */
                if (vrrp->ipsecah_counter->cycle) {
@@ -786,10 +786,12 @@ vrrp_fault(vrrp_rt * vrrp)
                vrrp_ah_sync(vrrp);
        } else {
                /* Otherwise, we transit to init state */
-               if (vrrp->init_state == VRRP_STATE_BACK)
+               if (vrrp->init_state == VRRP_STATE_BACK) {
                        vrrp->state = VRRP_STATE_BACK;
-               else
+                       notify_instance_exec(vrrp, VRRP_STATE_BACK);
+               } else {
                        vrrp_goto_master(vrrp);
+               }
        }
 }
 
index 4efada5..5a88be5 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        VRRP synchronization framework.
  *
- * Version:     $Id: vrrp_sync.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_sync.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index d154902..4e5442e 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Interface tracking framework.
  *
- * Version:     $Id: vrrp_track.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vrrp_track.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 0ee3040..66f78f0 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        HTML stream parser utility functions.
  *
- * Version:     $Id: html.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: html.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *
index c1375b0..680d546 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        parser.c include file.
  *
- * Version:     $Id: html.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: html.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *
index 90e2c95..7fd8931 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        List structure manipulation.
  *  
- * Version:     $Id: list.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: list.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 186f4b8..6884719 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        list.c include file.
  *  
- * Version:     $Id: list.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: list.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index d189d8e..0944efc 100644 (file)
@@ -6,7 +6,7 @@
  * Part:        Memory management framework. This framework is used to
  *              find any memory leak.
  *
- * Version:     $Id: memory.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: memory.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
index 38ecf55..3234994 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        memory.c include file.
  *
- * Version:     $Id: memory.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: memory.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Authors:     Alexandre Cassen, <acassen@linux-vs.org>
  *              Jan Holmberg, <jan@artech.net>
index 4d9bc7b..aa90231 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        Forked system call to launch an extra script.
  *
- * Version:     $Id: notify.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: notify.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 10893e8..95bfaaf 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        notify.c include file.
  *
- * Version:     $Id: notify.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: notify.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ae5d757..77eeeaa 100644 (file)
@@ -7,7 +7,7 @@
  *              data structure representation the conf file representing
  *              the loadbalanced server pool.
  *  
- * Version:     $Id: parser.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: parser.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
@@ -33,6 +33,7 @@
 
 /* global vars */
 vector keywords;
+vector current_keywords;
 FILE *current_stream;
 char *current_conf_file;
 int reload = 0;
@@ -213,7 +214,7 @@ void read_conf_file(char *conf_file)
                char *confpath = strdup(globbuf.gl_pathv[i]);
                dirname(confpath);
                chdir(confpath);
-               process_stream(keywords);
+               process_stream(current_keywords);
                fclose(stream);
 
                chdir(prev_path);
@@ -388,6 +389,8 @@ process_stream(vector keywords_vec)
        char *str;
        char *buf;
        vector strvec;
+       vector prev_keywords = current_keywords;
+       current_keywords = keywords_vec;
 
        buf = zalloc(MAXBUF);
        while (read_line(buf, MAXBUF)) {
@@ -423,6 +426,7 @@ process_stream(vector keywords_vec)
                free_strvec(strvec);
        }
 
+       current_keywords = prev_keywords;
        free(buf);
        return;
 }
@@ -442,6 +446,7 @@ init_data(char *conf_file, vector (*init_keywords) (void))
 #endif
 
        /* Stream handling */
+       current_keywords = keywords;
        read_conf_file((conf_file) ? conf_file : CONF);
        free_keywords(keywords);
 }
index 732c0c6..73824a8 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        cfreader.c include file.
  *  
- * Version:     $Id: parser.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: parser.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index ed7a245..25da492 100644 (file)
@@ -7,7 +7,7 @@
  *              the thread management routine (thread.c) present in the 
  *              very nice zebra project (http://www.zebra.org).
  *
- * Version:     $Id: scheduler.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: scheduler.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 64b67ef..1a144bb 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        scheduler.c include file.
  *
- * Version:     $Id: scheduler.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: scheduler.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index c31d16f..c0dff8a 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        Signals framework.
  *  
- * Version:     $Id: signals.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: signals.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Kevin Lindsay, <kevinl@netnation.com>
  *              Alexandre Cassen, <acassen@linux-vs.org>
index f74ae73..c6dfe9f 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        signals.c include file.
  *  
- * Version:     $Id: signals.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: signals.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Kevin Lindsay, <kevinl@netnation.com>
  *              Alexandre Cassen, <acassen@linux-vs.org>
index 1940008..b00aa38 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        Timer manipulations.
  *  
- * Version:     $Id: timer.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: timer.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index f744567..dba9f1c 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        timer.c include file.
  *  
- * Version:     $Id: timer.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: timer.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 5e39975..d2d17f1 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        General program utils.
  *
- * Version:     $Id: utils.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: utils.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 8c826b5..c89c5bd 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Part:        utils.h include file.
  *
- * Version:     $Id: utils.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: utils.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *
index 1a7ad3a..d4683dd 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        Vector structure manipulation.
  *  
- * Version:     $Id: vector.c,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vector.c,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  * 
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *              
index 69b7bb1..dd99327 100644 (file)
@@ -5,7 +5,7 @@
  * 
  * Part:        vector.c include file.
  *  
- * Version:     $Id: vector.h,v 1.1.14 2007/09/13 21:12:33 acassen Exp $
+ * Version:     $Id: vector.h,v 1.1.15 2007/09/15 04:07:41 acassen Exp $
  *
  * Author:      Alexandre Cassen, <acassen@linux-vs.org>
  *