From a3cae2a7299fcc3aa508fe0d13d98c4d9f1fe1d7 Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Wed, 10 Dec 2014 17:09:30 +0100 Subject: [PATCH] lldp: fix display of unknown organizational ID Because it was stored in a signed char array, it was incorrectly displayed with the "%x" formatter. Store it into an unsigned char array. --- src/daemon/lldp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/daemon/lldp.c b/src/daemon/lldp.c index ae01ccc5..3d0a988b 100644 --- a/src/daemon/lldp.c +++ b/src/daemon/lldp.c @@ -483,7 +483,7 @@ lldp_decode(struct lldpd *cfg, char *frame, int s, const char dot3[] = LLDP_TLV_ORG_DOT3; const char med[] = LLDP_TLV_ORG_MED; const char dcbx[] = LLDP_TLV_ORG_DCBX; - char orgid[3]; + unsigned char orgid[3]; int length, gotend = 0, ttl_received = 0; int tlv_size, tlv_type, tlv_subtype; u_int8_t *pos, *tlv; -- 2.47.2