conf: lock_file is derived config.
authorFerry Huberts <ferry.huberts@pelagic.nl>
Fri, 19 Jun 2015 12:03:02 +0000 (14:03 +0200)
committerFerry Huberts <ferry.huberts@pelagic.nl>
Fri, 19 Jun 2015 16:15:59 +0000 (18:15 +0200)
commita7326a0237929d366b97ba82d0079dd336c1320f
treeaedf4630bc1a56167f7396e625d73acb59bc5e93
parent043ee47f5a6213f30fb0eddf8c8f316e13303530
conf: lock_file is derived config.

Hi!

We're running two OLSRd instances on our routers (one IPv4, one IPv6).
0.9.x breaks with that setup since there seems to be a bug that causes
the default lockfile name always set to be "olsrd-ipv4.lock".

This bug seems to have been introduced in
http://www.olsr.org/git/?p=olsrd.git;a=commitdiff;h=089c78e208dcb0802ce93f47554a502ab8b77be5

olsrd_get_default_lockfile()
http://www.olsr.org/git/?p=olsrd.git;a=blob;f=src/cfgparser/olsrd_conf.c;h=30e2829cfd1be2717fc25639a9cbdb0da5fea466;hb=089c78e208dcb0802ce93f47554a502ab8b77be5#l976
always sees cnf->ip_version==AF_INET, as that's the default that was
just set in line 932.

Reported-by: Malte <freifunk@antenne.yagii.de>
Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
src/cfgparser/olsrd_conf.c
src/cfgparser/olsrd_conf.h
src/main.c