]> git.ipfire.org Git - thirdparty/lldpd.git/log
thirdparty/lldpd.git
12 years agobuild: ensure _GNU_SOURCE is defined early
Vincent Bernat [Sat, 22 Dec 2012 22:30:22 +0000 (23:30 +0100)] 
build: ensure _GNU_SOURCE is defined early

It is needed to use some extensions like `strnlen()`.

12 years agobuild: ship a include/ directory
Vincent Bernat [Sat, 22 Dec 2012 20:14:18 +0000 (21:14 +0100)] 
build: ship a include/ directory

Some (old) distributions are shipping outdated kernel headers. Some
oddities were detected in `configure` and corrected in `compat.h` but
this is cumbersome. Like `iproute`, we now ship a "complete" include/
directory containing the missing bits. It comes from a 3.6.9
kernel. Using too recent headers with too old kernel should not be a
problem. Those headers are just definition and there was not guarantee
that the kernel used to compile was the one which will be used to run.

12 years agointerfaces: harmonize arguments of detection functions
Vincent Bernat [Sat, 22 Dec 2012 19:25:23 +0000 (20:25 +0100)] 
interfaces: harmonize arguments of detection functions

Some detection functions were requiring a name, other an index. We
always use a `struct netlink_interface`. The only drawback is that
those functions can only be called in the context where this structure
exists, i.e when discovering interfaces. In the case of bonding, we
used one function to detect if the interface was active. We replace
this by an unconditional replacement of the source MAC address by 0.

12 years agolldpd: fix debug message when discarding a received frame
Vincent Bernat [Sat, 22 Dec 2012 19:23:07 +0000 (20:23 +0100)] 
lldpd: fix debug message when discarding a received frame

There are legit reasons to discard a received frame. This happens on
bond interfaces. Fix the message to just say we have discarded a
frame, not we are not able to receive something.

12 years agointerfaces: handle correctly VLAN inside VLAN inside bridges inside bonds
Vincent Bernat [Sat, 22 Dec 2012 18:49:15 +0000 (19:49 +0100)] 
interfaces: handle correctly VLAN inside VLAN inside bridges inside bonds

Recursively look for the physical interface.

12 years agointerfaces: switch to Netlink to gather interface-related information
Vincent Bernat [Thu, 20 Dec 2012 07:28:29 +0000 (08:28 +0100)] 
interfaces: switch to Netlink to gather interface-related information

Instead of using getifaddrs() which gives incomplete information, we
use Netlink which is supported since a long time. Many information are
supported by Netlink: bonding, bridging, VLAN... Unfortunately, the
degree of support depends on the version of the kernel:

 - IFLA_VLAN_* stuff is available since 2.6.23 only.
 - IFLA_MASTER seems to be supported since ages (at least
   2.4.32). However, it does not allow to differentiate a bridge and a
   bonding. It does not apply to a VLAN.
 - IFLA_LINK is not sent for a VLAN before 2.6.23.
 - IFLA_BRPORT_* has just landed in Linux.
 - IFLA_LINKINFO and IFLA_INFO_KIND which could help detect the kind
   of device are only available since 2.6.23.

So, in summary, we can't reliably use Netlink to gather VLAN, bridging
and bonding information if we want to support 2.6.18 kernels. When
2.6.23 will be the minimal version, we could do some interesting
things. Also, it seems that ethtool stuff is not available through
Netlink.

This commit also happens to prepare the support of additional OS. Only
interfaces-linux.c (and netlink.c) are now Linux specific. Adding
support for KFreeBSD should be easy enough. More code factorisation
will happen then.

12 years agobuild: make autogen.sh a little bit more generic
Vincent Bernat [Thu, 20 Dec 2012 08:23:01 +0000 (09:23 +0100)] 
build: make autogen.sh a little bit more generic

12 years agobuild: use a simplified autogen.sh script
Vincent Bernat [Wed, 19 Dec 2012 22:35:58 +0000 (23:35 +0100)] 
build: use a simplified autogen.sh script

The previous one was fairly complete but did not manage to generate
what was needed to get the build prepared. The bug is in autoreconf
which was calling `libtoolize` in `libevent` before doing it for the
main project. Hence, `ltmain.sh` was not found. It is still surprising
that we have such hackish build systems in 2012.

12 years agolibevent: use a git submodule
Vincent Bernat [Wed, 19 Dec 2012 21:15:27 +0000 (22:15 +0100)] 
libevent: use a git submodule

Instead of shipping the whole tarball for libevent in git, just use a
submodule against the official repository. ./autogen.sh is also
updated to be able to compile it.

12 years agotravis: workaround the fact that Travis images are not always up-to-date
Vincent Bernat [Mon, 17 Dec 2012 07:19:15 +0000 (08:19 +0100)] 
travis: workaround the fact that Travis images are not always up-to-date

12 years agolldpctl: new JSON output
Vincent Bernat [Mon, 17 Dec 2012 06:48:02 +0000 (07:48 +0100)] 
lldpctl: new JSON output

JSON output is done with "Jansson", a convenient JSON library. The
output may be a bit difficult to use when a multivalued field with
only one value is present. In this case, it is not put into an
array. For example, if there is only one neighbor, you get:
`{interface:{eth0: ...}}` while you will get this for two neighbors:
`{interface:[{eth0:...},{eth1:...}]}`.

12 years agolog: remove extra linefeeds from log_*() and fatal*() calls
Vincent Bernat [Mon, 17 Dec 2012 04:35:25 +0000 (05:35 +0100)] 
log: remove extra linefeeds from log_*() and fatal*() calls

12 years agoNEWS: add a mention about the fact we can filter debug logs
Vincent Bernat [Sun, 16 Dec 2012 15:15:41 +0000 (16:15 +0100)] 
NEWS: add a mention about the fact we can filter debug logs

12 years agolog: add -D option to filter out debug logs
Vincent Bernat [Sun, 16 Dec 2012 14:58:14 +0000 (15:58 +0100)] 
log: add -D option to filter out debug logs

The list of accepted tokens is documented in the manual page.

12 years agolog: convert LLOG_* to log_* and add more debug logs
Vincent Bernat [Sun, 16 Dec 2012 14:10:54 +0000 (15:10 +0100)] 
log: convert LLOG_* to log_* and add more debug logs

Convert all call to LLOG_* to log_* with prefix. Also convert
fatal/fatalx calls. Add more debugging since we will soon be able to
filter them.

12 years agosnmp: don't send traps when SNMP is not enabled
Vincent Bernat [Sun, 16 Dec 2012 12:35:21 +0000 (13:35 +0100)] 
snmp: don't send traps when SNMP is not enabled

12 years agolog: prefix logs with a token to allow filtering
Vincent Bernat [Sun, 16 Dec 2012 12:12:51 +0000 (13:12 +0100)] 
log: prefix logs with a token to allow filtering

Currently, the token defaults to the filename. Filtering has yet to be
done.

12 years agolog: enhance logging output
Vincent Bernat [Sun, 16 Dec 2012 11:34:36 +0000 (12:34 +0100)] 
log: enhance logging output

Append the current date in front of the log line. Display the
priority. Add some colors when logging on a TTY.

12 years agocompile: remove a warning about uninitialized struct
Vincent Bernat [Sun, 16 Dec 2012 11:27:53 +0000 (12:27 +0100)] 
compile: remove a warning about uninitialized struct

12 years agoUpdate to libevent 2.0.21.
Vincent Bernat [Mon, 19 Nov 2012 22:00:06 +0000 (23:00 +0100)] 
Update to libevent 2.0.21.

12 years agolldpd: add possibility to disable LLDP
Vincent Bernat [Mon, 12 Nov 2012 15:36:55 +0000 (16:36 +0100)] 
lldpd: add possibility to disable LLDP

LLDP was mandatory. It is now possible to disable it entirely with
`-ll`. In this case, when no neighbor is detected, the first enabled
protocol will be used. For example, with `-ll -c`, lldpd will act as a
pure CDP daemon.

12 years agolldp: fix parsing of LLDP pair control
Vincent Bernat [Thu, 25 Oct 2012 05:39:21 +0000 (07:39 +0200)] 
lldp: fix parsing of LLDP pair control

Thanks to Viktor Dukhovni for noticing this bug.

12 years agobuild: don't use a comment at start of rule (unportable)
Vincent Bernat [Wed, 26 Sep 2012 22:23:54 +0000 (00:23 +0200)] 
build: don't use a comment at start of rule (unportable)

12 years agobuild: build an empty changelog if not available
Vincent Bernat [Wed, 26 Sep 2012 22:14:01 +0000 (00:14 +0200)] 
build: build an empty changelog if not available

12 years agoredhat: don't build SNMP support on CentOS
Vincent Bernat [Wed, 26 Sep 2012 21:50:18 +0000 (23:50 +0200)] 
redhat: don't build SNMP support on CentOS

12 years agolib: silent some compiler warning about unitialized value
Vincent Bernat [Wed, 26 Sep 2012 21:37:45 +0000 (23:37 +0200)] 
lib: silent some compiler warning about unitialized value

12 years agobuild: install ChangeLog in /usr/share/doc
Vincent Bernat [Wed, 26 Sep 2012 21:37:25 +0000 (23:37 +0200)] 
build: install ChangeLog in /usr/share/doc

12 years agodebian/redhat: update packaging
Vincent Bernat [Wed, 26 Sep 2012 21:04:46 +0000 (23:04 +0200)] 
debian/redhat: update packaging

12 years agointerfaces: don't listen to enslaved interface until master interface has been configured
Vincent Bernat [Wed, 26 Sep 2012 19:08:08 +0000 (21:08 +0200)] 
interfaces: don't listen to enslaved interface until master interface has been configured

In case of errors, we were leaking events.

12 years agobuild: use AC_PROG_CC_C99 instead of -std=gnu99
Vincent Bernat [Thu, 20 Sep 2012 21:49:42 +0000 (23:49 +0200)] 
build: use AC_PROG_CC_C99 instead of -std=gnu99

Use of C99 is mandatory but not all compilers will support
-std=gnu99 (which is GCC specific). Autoconf comes with the
appropriate macro for this.

12 years agodisplay: fix display of various Dot3 advertised links
Vincent Bernat [Thu, 20 Sep 2012 14:34:44 +0000 (16:34 +0200)] 
display: fix display of various Dot3 advertised links

12 years agolibevent: upgrade embedded copy to 2.0.20.
Vincent Bernat [Tue, 11 Sep 2012 22:23:13 +0000 (00:23 +0200)] 
libevent: upgrade embedded copy to 2.0.20.

12 years agoconst: fix a type in LLDP_DOT3_MAU_100BASET2FD
Vincent Bernat [Mon, 10 Sep 2012 07:12:22 +0000 (09:12 +0200)] 
const: fix a type in LLDP_DOT3_MAU_100BASET2FD

12 years agotravis: use only two sets of configure options and check "distcheck" and "install...
Vincent Bernat [Sat, 8 Sep 2012 13:03:09 +0000 (15:03 +0200)] 
travis: use only two sets of configure options and check "distcheck" and "install" targets

12 years agobuild: fix compilation without LLDP MED
Vincent Bernat [Sat, 8 Sep 2012 13:00:05 +0000 (15:00 +0200)] 
build: fix compilation without LLDP MED

12 years agobuild: move manual page next to the source code 0.6.1
Vincent Bernat [Tue, 4 Sep 2012 19:10:49 +0000 (21:10 +0200)] 
build: move manual page next to the source code

In the future, this will allow to generate part of the manual page.

12 years agobuild: add author name and commit hash in generated changelog
Vincent Bernat [Sun, 2 Sep 2012 07:49:47 +0000 (09:49 +0200)] 
build: add author name and commit hash in generated changelog

12 years agosnmp: add lldpRemTablesChange notification
Vincent Bernat [Sat, 1 Sep 2012 18:10:32 +0000 (20:10 +0200)] 
snmp: add lldpRemTablesChange notification

As per the description of the MIB, the following objects are sent with
the notification:

        lldpStatsRemTablesInserts,
        lldpStatsRemTablesDeletes,
        lldpStatsRemTablesDrops,
        lldpStatsRemTablesAgeouts

However, we also send (except on deletion):

        lldpLocPortDesc
        lldpRemSysName
        lldpRemPortDesc

12 years agolldpd: add proper insert/delete/ageout counters
Vincent Bernat [Sat, 1 Sep 2012 17:20:37 +0000 (19:20 +0200)] 
lldpd: add proper insert/delete/ageout counters

12 years agogeneral: use "TX interval" instead of "TX delay" to be more coherent with the MIB
Vincent Bernat [Sat, 1 Sep 2012 16:54:28 +0000 (18:54 +0200)] 
general: use "TX interval" instead of "TX delay" to be more coherent with the MIB

12 years agodoc: add appropriate titles to groups in lldpctl.h
Vincent Bernat [Sat, 1 Sep 2012 15:42:53 +0000 (17:42 +0200)] 
doc: add appropriate titles to groups in lldpctl.h

12 years agodoc: polish documentation of liblldpctl
Vincent Bernat [Sat, 1 Sep 2012 15:36:10 +0000 (17:36 +0200)] 
doc: polish documentation of liblldpctl

12 years agotests: fix tests compilation
Vincent Bernat [Fri, 31 Aug 2012 21:06:24 +0000 (23:06 +0200)] 
tests: fix tests compilation

Some tests were not compilable any more due to previous changes in
`struct lldpd`.

12 years agobuild: fix "make dist"
Vincent Bernat [Fri, 31 Aug 2012 21:02:54 +0000 (23:02 +0200)] 
build: fix "make dist"

12 years agolldpctl: add the possibility to force lldpd to start the main loop now
Vincent Bernat [Fri, 31 Aug 2012 16:43:05 +0000 (18:43 +0200)] 
lldpctl: add the possibility to force lldpd to start the main loop now

12 years agolldpctl: allow to display global configuration of lldpd
Vincent Bernat [Fri, 31 Aug 2012 15:35:05 +0000 (17:35 +0200)] 
lldpctl: allow to display global configuration of lldpd

12 years agolldpd: move configuration stuff into a dedicated structure
Vincent Bernat [Fri, 31 Aug 2012 09:52:20 +0000 (11:52 +0200)] 
lldpd: move configuration stuff into a dedicated structure

Configuration stuff was mixed with runtime stuff in `struct lldpd`. We
put the configuration stuff into an appropriate structure to be able
to export it to lldpctl.

12 years agolldpctl: just require access to the socket for actions, not root priv
Vincent Bernat [Fri, 31 Aug 2012 06:01:57 +0000 (08:01 +0200)] 
lldpctl: just require access to the socket for actions, not root priv

Instead of checking for root, we check that we don't have additional
privileges due to setuid or setgid binary.

12 years agomarshal: don't marshal the list of chassis
Vincent Bernat [Fri, 31 Aug 2012 05:52:43 +0000 (07:52 +0200)] 
marshal: don't marshal the list of chassis

We never need a list of chassis, just one chassis. Therefore, some
code is simplified by not transmitting the list.

12 years agoctl: fix reception of several messages at once
Vincent Bernat [Fri, 31 Aug 2012 05:42:33 +0000 (07:42 +0200)] 
ctl: fix reception of several messages at once

When receiving several messages at once, memmove() was incorrectly
used. This resulted into a segfault.

12 years agoctl: don't serialize notification if no client needs it
Vincent Bernat [Thu, 30 Aug 2012 23:08:23 +0000 (01:08 +0200)] 
ctl: don't serialize notification if no client needs it

The serialization of the notification is done only if some client is
registered for it.

12 years agoctl: increase maximum message size to 512 KB
Vincent Bernat [Thu, 30 Aug 2012 23:05:51 +0000 (01:05 +0200)] 
ctl: increase maximum message size to 512 KB

This can now be done safely since we don't rely on message boundaries
anymore.

12 years agolldpctl: add a "-w" option to watch neighbor changes
Vincent Bernat [Thu, 30 Aug 2012 22:59:30 +0000 (00:59 +0200)] 
lldpctl: add a "-w" option to watch neighbor changes

12 years agoclient: use libevent's bufferevent infrastructure to handle clients
Vincent Bernat [Thu, 30 Aug 2012 12:53:27 +0000 (14:53 +0200)] 
client: use libevent's bufferevent infrastructure to handle clients

Previously, lldpd would block if the unix socket with the client was
full (buggy client). This was not really a problem since a client
needs to output some data to get some other data and therefore only
evil clients may block lldpd. However, with (future) notifications, a
hang client could stop lldpd from working. We may still eat a lot of
memory if a client stay stuck.

12 years agoSeparate daemon and client code. Provide a client library.
Vincent Bernat [Tue, 14 Aug 2012 15:06:23 +0000 (17:06 +0200)] 
Separate daemon and client code. Provide a client library.

In `daemon/`, we have what is exclusively used by lldpd. In `client/`,
we have what is exclusively used by lldpctl and in `lib/`, we have a
library that will talk to the daemon and can be used to build other
clients. lldpctl is using this library.

This is a mega commit.

There are also some extra little changes, notably, adding a line to
each file to set "openbsd" as the default C style.

12 years agodist: provide a complete changelog
Vincent Bernat [Wed, 15 Aug 2012 12:07:31 +0000 (14:07 +0200)] 
dist: provide a complete changelog

The previous changelog is moved to a NEWS file

12 years agoprivsep: copy errno before sending it
Vincent Bernat [Sun, 1 Jul 2012 08:06:37 +0000 (10:06 +0200)] 
privsep: copy errno before sending it

errno may be erased by some other value while sending it. We do a copy
and send the copy instead.

12 years agoredhat: properly restart lldpd on upgrade
Vincent Bernat [Fri, 29 Jun 2012 04:28:11 +0000 (06:28 +0200)] 
redhat: properly restart lldpd on upgrade

12 years agosnmp: remove extra '\n' at the end of SNMP log message
Vincent Bernat [Wed, 20 Jun 2012 16:45:19 +0000 (18:45 +0200)] 
snmp: remove extra '\n' at the end of SNMP log message

Putting `\0` is useless. The code was done to remove an extra `\n`.

13 years agolldpd: demote "unable to guess" to debug
Vincent Bernat [Wed, 30 May 2012 08:41:23 +0000 (10:41 +0200)] 
lldpd: demote "unable to guess" to debug

This message can happen fairly often if some protocol is not enabled
in lldpd without being a problem. It fills system daemon logs. Send it
only to debug level.

This should close #19.

13 years agolldpd: disable SIGPIPE signal
Vincent Bernat [Thu, 24 May 2012 17:10:34 +0000 (19:10 +0200)] 
lldpd: disable SIGPIPE signal

13 years agoconfigure: cleanup libevent integration
Vincent Bernat [Sat, 19 May 2012 14:27:51 +0000 (16:27 +0200)] 
configure: cleanup libevent integration

13 years agoAdd a `-v` flag to just get version number.
Vincent Bernat [Fri, 18 May 2012 05:33:47 +0000 (07:33 +0200)] 
Add a `-v` flag to just get version number.

Closes #18.

13 years agoState that the license is usually referred as the ISC license.
Vincent Bernat [Thu, 17 May 2012 18:47:33 +0000 (20:47 +0200)] 
State that the license is usually referred as the ISC license.

13 years agolldpd: listen on Unix socket before forking
Vincent Bernat [Fri, 11 May 2012 05:53:39 +0000 (07:53 +0200)] 
lldpd: listen on Unix socket before forking

This way, lldpd Unix socket is ready to operate when lldpd detaches
itself from the terminal. This mean that lldpctl can be used right
away.

This change also removes the need to create this socket using
privilege separation operations.

13 years agoautomake: libevent.la is not a convenience library 0.6.0
Vincent Bernat [Fri, 4 May 2012 20:22:56 +0000 (22:22 +0200)] 
automake: libevent.la is not a convenience library

Since libevent.la is not a convenience library, we cannot merge it
into liblldpd.la. Therefore, we link it to lldpd directly (and don't
try to build a convenience library from it).

13 years agoclient: fix unused variable when LLDPMED support is not compiled
Vincent Bernat [Fri, 4 May 2012 16:35:32 +0000 (18:35 +0200)] 
client: fix unused variable when LLDPMED support is not compiled

13 years agomarshal: use zero-sized array instead of flexible arrays
Vincent Bernat [Fri, 4 May 2012 09:48:40 +0000 (11:48 +0200)] 
marshal: use zero-sized array instead of flexible arrays

With gcc 2.96, flexible arrays are not supported, even with
-std=gnu99. And with gcc 3.x, zero-sized arrays cannot be statically
initialized (with more than one element).

13 years agoDon't mix declarations and statements.
Vincent Bernat [Fri, 4 May 2012 06:11:36 +0000 (08:11 +0200)] 
Don't mix declarations and statements.

Also enable warnings when we try to. Compatibility with gcc 2.96 requires that.

13 years agoconfigure: don't check for SLIST_* stuff: we don't use them
Vincent Bernat [Fri, 4 May 2012 05:33:10 +0000 (07:33 +0200)] 
configure: don't check for SLIST_* stuff: we don't use them

13 years agosnmp: only call run_alarms() on SNMP timeouts
Vincent Bernat [Thu, 3 May 2012 08:59:42 +0000 (10:59 +0200)] 
snmp: only call run_alarms() on SNMP timeouts

See snmp_alarm(3snmp) manual page for the
rationale. `NETSNMP_DS_LIB_ALARM_DONT_USE_SIG` is set by
`init_agent()`.

13 years agoconfigure: make ./autogen.sh non recursive
Vincent Bernat [Wed, 2 May 2012 17:57:51 +0000 (19:57 +0200)] 
configure: make ./autogen.sh non recursive

13 years agoconfigure: use AC_PROG_CXX macro
Vincent Bernat [Wed, 2 May 2012 17:55:05 +0000 (19:55 +0200)] 
configure: use AC_PROG_CXX macro

13 years agoconfigure: always configure libevent to make "make dist" work
Vincent Bernat [Wed, 2 May 2012 17:05:13 +0000 (19:05 +0200)] 
configure: always configure libevent to make "make dist" work

13 years agoctl: no need to keep a list of active clients
Vincent Bernat [Wed, 2 May 2012 14:16:41 +0000 (16:16 +0200)] 
ctl: no need to keep a list of active clients

13 years agoReally ship libevent.
Vincent Bernat [Wed, 2 May 2012 13:52:53 +0000 (15:52 +0200)] 
Really ship libevent.

13 years agoShip an embedded copy of libevent.
Vincent Bernat [Wed, 2 May 2012 10:50:09 +0000 (12:50 +0200)] 
Ship an embedded copy of libevent.

This embedded copy will only be used if no system libevent is
available.

13 years agoconfigure: don't test for XML2 linking, useless
Vincent Bernat [Wed, 2 May 2012 06:12:03 +0000 (08:12 +0200)] 
configure: don't test for XML2 linking, useless

Just check for its presence with pkg-config and xml2-config.

13 years agoconfigure: remove old unwanted cruft
Vincent Bernat [Wed, 2 May 2012 06:03:22 +0000 (08:03 +0200)] 
configure: remove old unwanted cruft

It seems easier to fail on compilation if we cannot provide a
workaround in configure.

13 years agoconfigure: drop dependency with libtool
Vincent Bernat [Tue, 1 May 2012 14:02:09 +0000 (16:02 +0200)] 
configure: drop dependency with libtool

13 years agoconfigure: enable compilation of a libevent archive
Vincent Bernat [Tue, 1 May 2012 13:28:41 +0000 (15:28 +0200)] 
configure: enable compilation of a libevent archive

README.md has been updated for those instructions. We still rely on
libtool to make this work. Unfortunately, the generated libtool comes
too late: we can't use it...

13 years agoUpdate changelog, travis and packaging for libevent
Vincent Bernat [Tue, 1 May 2012 09:29:22 +0000 (11:29 +0200)] 
Update changelog, travis and packaging for libevent

13 years agolldpd: switch to libevent loop
Vincent Bernat [Mon, 30 Apr 2012 23:33:42 +0000 (01:33 +0200)] 
lldpd: switch to libevent loop

This is a major change. Instead of a custom loop, we switch to
libevent. Only `levent.c` is aware of the event loop. Other parts do
not manipulate events. Currently, we still have a loop triggered every
30 seconds. This could change to be a per port handling.

13 years agoconfigure: upgrade to libevent 2.x
Vincent Bernat [Fri, 27 Jan 2012 11:30:41 +0000 (12:30 +0100)] 
configure: upgrade to libevent 2.x

Also, when linking with a static version of libevent, we enforce the
use of libtool ".la" file instead of ".a" to get appropriate
dependencies automatically and avoid a warning when linking inside a
".la".

13 years agoIntegration of libevent into the build system.
Vincent Bernat [Thu, 1 Jul 2010 09:29:48 +0000 (11:29 +0200)] 
Integration of libevent into the build system.

"configure" will check that libevent is present. It is possible to use
--with-libevent option to tell where libevent lives. We include the
possibility to use a static copy of libevent but with the absence of a
.pc file, we are not sure to handle all the dependencies correctly.

README file is updated with instructions about libevent, including
steps to build libevent inside lldpd.

13 years agolldpd: on exit, remove remote ports before removing local ones
Vincent Bernat [Tue, 1 May 2012 09:09:15 +0000 (11:09 +0200)] 
lldpd: on exit, remove remote ports before removing local ones

13 years agolldpd: fix chassis copy
Vincent Bernat [Tue, 1 May 2012 08:54:05 +0000 (10:54 +0200)] 
lldpd: fix chassis copy

When a chassis is already known, we copy the new one over the old one
and keep the old one. With the addition of management addresses as a
list, the copy was incorrect. We fix it. This is kludgy. A better way
would be to use marshaling but marshaling is not able to do inplace
copy and it is not able to restore full list (previous pointer is not
restored).

13 years agovalgrind: initialize some buffers to make valgrind happy
Vincent Bernat [Tue, 1 May 2012 08:16:10 +0000 (10:16 +0200)] 
valgrind: initialize some buffers to make valgrind happy

Valgrind does not understand some ioctl and thinks we are using
unitialized buffers while the ioctl will initialize them. We get rid
of those warnings by initializing them ourselves.

13 years agoWhen running on valgrind, don't chroot or drop privileges
Vincent Bernat [Mon, 30 Apr 2012 23:50:03 +0000 (01:50 +0200)] 
When running on valgrind, don't chroot or drop privileges

Valgrind documentation says:

  You are encouraged to copy the valgrind/*.h headers into your
  project's include directory, so your program doesn't have a
  compile-time dependency on Valgrind being installed. The Valgrind
  headers, unlike most of the rest of the code, are under a BSD-style
  license so you may include them without worrying about license
  incompatibility.

I don't like copying headers around. Therefore, there is an autoconf
check for valgrind headers.

13 years agotravis: add Travis CI link to README
Vincent Bernat [Tue, 3 Apr 2012 13:25:35 +0000 (15:25 +0200)] 
travis: add Travis CI link to README

13 years agotests: when Dot3 feature is disabled, MFS is not transmitted
Vincent Bernat [Tue, 3 Apr 2012 11:37:49 +0000 (13:37 +0200)] 
tests: when Dot3 feature is disabled, MFS is not transmitted

13 years agoAllow compilation without Dot1.
Vincent Bernat [Tue, 3 Apr 2012 11:29:47 +0000 (13:29 +0200)] 
Allow compilation without Dot1.

13 years agotravis: use apt-get instead of aptitude
Vincent Bernat [Tue, 3 Apr 2012 11:21:00 +0000 (13:21 +0200)] 
travis: use apt-get instead of aptitude

aptitude will try to remove unused packages. We don't need this. Also,
enable XML output.

13 years agotravis: use provided configure argument
Vincent Bernat [Tue, 3 Apr 2012 11:10:45 +0000 (13:10 +0200)] 
travis: use provided configure argument

Also install "check" package to enable unittests.

13 years agoIntegration with Travis CI
Vincent Bernat [Tue, 3 Apr 2012 11:03:25 +0000 (13:03 +0200)] 
Integration with Travis CI

13 years agomgmt: allow one to provide a pattern to specify management addresses
Vincent Bernat [Thu, 15 Mar 2012 22:28:55 +0000 (23:28 +0100)] 
mgmt: allow one to provide a pattern to specify management addresses

13 years agoUpdate CHANGELOG with entry about management addresses.
Vincent Bernat [Thu, 15 Mar 2012 21:56:01 +0000 (22:56 +0100)] 
Update CHANGELOG with entry about management addresses.

13 years agosnmp: add support for IPv6 management addresses
Vincent Bernat [Thu, 15 Mar 2012 21:51:48 +0000 (22:51 +0100)] 
snmp: add support for IPv6 management addresses

13 years agosnmp: fix SNMP support for management addresses
Vincent Bernat [Thu, 15 Mar 2012 21:29:01 +0000 (22:29 +0100)] 
snmp: fix SNMP support for management addresses

13 years agoedp: ensure we don't add the same address over and over
Vincent Bernat [Thu, 15 Mar 2012 21:02:48 +0000 (22:02 +0100)] 
edp: ensure we don't add the same address over and over

We still need to discards address that are not advertised
anymore. However, that's not easy.