From 7d4866548d028489d84c39af1bb9206842a77b2b Mon Sep 17 00:00:00 2001 From: David Herrmann Date: Wed, 31 Dec 2014 16:07:17 +0100 Subject: lldp: fix uninitialized cleanup var #2 Another uninitialized variable marked as _cleanup_. Set it to NULL to avoid accessing uninitialized memory. --- src/libsystemd-network/lldp-internal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/libsystemd-network/lldp-internal.c b/src/libsystemd-network/lldp-internal.c index d03445b1e2..f843fd256d 100644 --- a/src/libsystemd-network/lldp-internal.c +++ b/src/libsystemd-network/lldp-internal.c @@ -496,7 +496,7 @@ int lldp_chassis_new(tlv_packet *tlv, Prioq *by_expiry, Hashmap *neighbour_mib, lldp_chassis **ret) { - _cleanup_lldp_chassis_free_ lldp_chassis *c; + _cleanup_lldp_chassis_free_ lldp_chassis *c = NULL; uint16_t length; uint8_t *data; uint8_t type; -- cgit v1.2.3-54-g00ecf