From: Luke Howard Date: Mon, 2 Dec 2013 06:09:03 +0000 (+1100) Subject: zeroAndReleasePassword must be called with non-NULL buffer X-Git-Tag: 0.9.2~15 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=mech_eap.git;a=commitdiff_plain;h=6e7e5f748f454f86e407327b820fc9f0c8360df5 zeroAndReleasePassword must be called with non-NULL buffer --- diff --git a/mech_eap/util_cred.c b/mech_eap/util_cred.c index 487aa47..06bea24 100644 --- a/mech_eap/util_cred.c +++ b/mech_eap/util_cred.c @@ -72,6 +72,8 @@ gssEapAllocCred(OM_uint32 *minor, gss_cred_id_t *pCred) static void zeroAndReleasePassword(gss_buffer_t password) { + GSSEAP_ASSERT(password != GSS_C_NO_BUFFER); + if (password->value != NULL) { memset(password->value, 0, password->length); GSSEAP_FREE(password->value);