Fix template issue in IPv6 host header.
unify logging of RS and VS

This fixes the bug of displaying a FWM service as [x.x.x.x]:0,
where x.x.x.x is the first RS of that service
unify connection options among checkers

All the remote checkers (TCP, HTTP/SSL, SMTP) now have the same set of connection options:
 * connect_ip (new to TCP, HTTP)
 * connect_port
 * bindto
 * bind_port  (new)
 * connect_timeout (new to SMTP)

All of them are optional with reasonable defaults.
The patch is designed for simplicity in adding a new option.

Since the connect_ip could be inequal to the RS address and, worse, the same for all RSes,
the endpoint is now logged as [RS]:rport, not the [connect_ip]:connect_port.
fwmark connection option
make SO_MARK a compile-time option
documentation for generic connection opts
random delay before doing the first check

every RS check is registered with a random delay
between 0 and vs->delay_loop seconds. It helps
avoiding multiple simultaneous checks to the same RS server.
vrrp: Proper restore of VMAC interface properties on SIGHUP

On SIGHUP the VMAC flag and base ifindex for a VMAC interface was lost.

Signed-off-by: Jonas Johansson <jonasj76@gmail.com>
Merge pull request #84 from jonasj76/vmac-sighup

Proper restore of VMAC interface properties on SIGHUP
vrrp: Let only base interface change the VMAC interface status flags

The interface status flags for a VMAC interface shall only be changed by the
base interface, never by reading the actual VMAC interface flags.

Signed-off-by: Jonas Johansson <jonasj76@gmail.com>
Merge pull request #85 from jonasj76/vmac-startup

vrrp: Let only base interface change the VMAC interface status flags
Merge branch 'master' into to_acassen

Conflicts:
	keepalived/check/ipwrapper.c
Merge pull request #83 from andriyanov/to_acassen

Great Work ! Thanks Alexey !
clarify the type of 'warmup' struct member

Initially the warmup field of the checker struct contained number of seconds
and was typed as unsigned int. Then it was changed to store timer ticks, but
the type was not changed to long as for other variables storing timer ticks.

This commit fixes this minor arch-specific issue.
Merge pull request #87 from andriyanov/fix_warmup_type

clarify the type of 'warmup' struct member
Merge pull request #75 from jhaprins/master

Fix template issue in IPv6 host header.
vrrp: fix ip_address comparison

Extend IP_ISEQ() macro to take care of NULL addresses. This issue end on
SEGV while using virtual_route. thanks to Tore Anderson for reporting.
Merge branch 'master' of github.com:acassen/keepalived
vrrp: fix double close issue (DROP_MEMBERSHIP & netlink channel)

This is a old pending 'bug', not arming at all but just frustrating
to see again and again this log message :

"cant do IP_DROP_MEMBERSHIP errno=Bad file descriptor (9)"

What the hell ! it was due to a double close during reload &
stop procedure. VRRP fd are stored in a socket pool and use
the I/O MUX to handle VRRP traffic. While reloading or stopping
the daemon the I/O MUX was released first and secondly socket pool.
The issue spotted here, in thread_destroy_master() all pending
thread are canceled and read/write fds related are close().

Well OK a close on a mcast socket perform kernel side the
DROP_MEMBERSHIP when needed, but it is much more clean to
perform proper operations userspace !

This patch sequencely cancel pending thread, release socket pool
and finally destroy master thread.

Same 'issue' appear in netlink channel.
keepalived-1.2.13