From 580e55da1118870b6099d1a863d9806a31f2b1b4 Mon Sep 17 00:00:00 2001 From: David Herrmann Date: Wed, 31 Dec 2014 15:58:27 +0100 Subject: lldp: fix double free 'k' is marked as _cleanup_free_ so reset it to NULL if we free it explicitly. --- src/libsystemd-network/sd-lldp.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/libsystemd-network/sd-lldp.c') diff --git a/src/libsystemd-network/sd-lldp.c b/src/libsystemd-network/sd-lldp.c index 08cd092213..74ea810c82 100644 --- a/src/libsystemd-network/sd-lldp.c +++ b/src/libsystemd-network/sd-lldp.c @@ -484,6 +484,7 @@ int sd_lldp_save(sd_lldp *lldp, const char *lldp_file) { t = strappend(s, buf); free(k); + k = NULL; } else { mac = port_id; -- cgit v1.2.3