From: Martin Willi Date: Thu, 9 Jan 2014 14:00:09 +0000 (+0100) Subject: libnccs: Fix casts between integers and pointers X-Git-Tag: 5.2.0dr6~24^2~48 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=becc382101ed9f53b03fd6c2013d6b710d17c59b;p=thirdparty%2Fstrongswan.git libnccs: Fix casts between integers and pointers --- diff --git a/src/libtnccs/plugins/tnc_imc/tnc_imc.c b/src/libtnccs/plugins/tnc_imc/tnc_imc.c index 6af8d166d4..623da7f627 100644 --- a/src/libtnccs/plugins/tnc_imc/tnc_imc.c +++ b/src/libtnccs/plugins/tnc_imc/tnc_imc.c @@ -97,7 +97,7 @@ METHOD(imc_t, add_id, void, void *pointer; /* store the scalar value in the pointer */ - pointer = (void*)id; + pointer = (void*)(uintptr_t)id; this->additional_ids->insert_last(this->additional_ids, pointer); } @@ -126,7 +126,7 @@ METHOD(imc_t, has_id, bool, while (enumerator->enumerate(enumerator, &pointer)) { /* interpret pointer as scalar value */ - additional_id = (TNC_UInt32)pointer; + additional_id = (uintptr_t)pointer; if (id == additional_id) {