aboutsummaryrefslogtreecommitdiff
path: root/lib/lacp.c
diff options
context:
space:
mode:
authorEthan Jackson <ethan@nicira.com>2011-11-29 13:22:18 -0800
committerEthan Jackson <ethan@nicira.com>2011-11-30 14:52:00 -0800
commit69fdadb1a9528ffb1a800ebd6997c826e55df972 (patch)
tree3a26b13a99f79053087e108f0b259dd3ae22d29a /lib/lacp.c
parent6a542738b2a59f98831fa36e6208d388c007d0b8 (diff)
lacp: Require non-zero system ID.
It's a bug if LACP is configured with a system ID of zero. This patch assert fails in this case.
Diffstat (limited to 'lib/lacp.c')
-rw-r--r--lib/lacp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/lacp.c b/lib/lacp.c
index 22cba942..6ee55c36 100644
--- a/lib/lacp.c
+++ b/lib/lacp.c
@@ -224,6 +224,8 @@ lacp_destroy(struct lacp *lacp)
void
lacp_configure(struct lacp *lacp, const struct lacp_settings *s)
{
+ assert(!eth_addr_is_zero(s->id));
+
if (!lacp->name || strcmp(s->name, lacp->name)) {
free(lacp->name);
lacp->name = xstrdup(s->name);