diff --git a/lib/gssapi/krb5/acquire_cred.c b/lib/gssapi/krb5/acquire_cred.c index aae525395..a2d2bcd6c 100644 --- a/lib/gssapi/krb5/acquire_cred.c +++ b/lib/gssapi/krb5/acquire_cred.c @@ -926,7 +926,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_acquire_cred_from NULL, time_rec, NULL, actual_mechs); if (ret != GSS_S_COMPLETE) { if (handle->mechanisms != NULL) - gss_release_oid_set(NULL, &handle->mechanisms); + gss_release_oid_set(minor_status, &handle->mechanisms); HEIMDAL_MUTEX_destroy(&handle->cred_id_mutex); krb5_free_principal(context, handle->principal); free(handle); diff --git a/lib/gssapi/krb5/add_cred.c b/lib/gssapi/krb5/add_cred.c index 0bc61a7be..be60a3d7d 100644 --- a/lib/gssapi/krb5/add_cred.c +++ b/lib/gssapi/krb5/add_cred.c @@ -238,6 +238,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_add_cred_from ( failure: if (handle) { + OM_uint32 tmp_status; if (handle->principal) krb5_free_principal(context, handle->principal); if (handle->keytab) @@ -245,7 +246,7 @@ failure: if (handle->ccache) krb5_cc_destroy(context, handle->ccache); if (handle->mechanisms) - gss_release_oid_set(NULL, &handle->mechanisms); + gss_release_oid_set(&tmp_status, &handle->mechanisms); free(handle); } if (cred && output_cred_handle) diff --git a/lib/gssapi/krb5/inquire_context.c b/lib/gssapi/krb5/inquire_context.c index 8fc0129b0..3d21b0fda 100644 --- a/lib/gssapi/krb5/inquire_context.c +++ b/lib/gssapi/krb5/inquire_context.c @@ -100,11 +100,12 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_inquire_context ( return GSS_S_COMPLETE; failed: + { OM_uint32 tmp_status; if (src_name) - _gsskrb5_release_name(NULL, src_name); + _gsskrb5_release_name(&tmp_status, src_name); if (targ_name) - _gsskrb5_release_name(NULL, targ_name); - + _gsskrb5_release_name(&tmp_status, targ_name); + } HEIMDAL_MUTEX_unlock(&ctx->ctx_id_mutex); return ret; } diff --git a/lib/gssapi/krb5/inquire_mechs_for_name.c b/lib/gssapi/krb5/inquire_mechs_for_name.c index c6c67464f..b5c669e07 100644 --- a/lib/gssapi/krb5/inquire_mechs_for_name.c +++ b/lib/gssapi/krb5/inquire_mechs_for_name.c @@ -40,6 +40,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_inquire_mechs_for_name ( ) { OM_uint32 ret; + OM_uint32 tmp_status; ret = gss_create_empty_oid_set(minor_status, mech_types); if (ret) @@ -49,7 +50,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_inquire_mechs_for_name ( GSS_KRB5_MECHANISM, mech_types); if (ret) - gss_release_oid_set(NULL, mech_types); + gss_release_oid_set(&tmp_status, mech_types); return ret; } diff --git a/lib/gssapi/krb5/inquire_names_for_mech.c b/lib/gssapi/krb5/inquire_names_for_mech.c index 65bd49c97..e7d57c514 100644 --- a/lib/gssapi/krb5/inquire_names_for_mech.c +++ b/lib/gssapi/krb5/inquire_names_for_mech.c @@ -48,6 +48,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_inquire_names_for_mech ( ) { OM_uint32 ret; + OM_uint32 tmp_status; int i; *minor_status = 0; @@ -71,7 +72,7 @@ OM_uint32 GSSAPI_CALLCONV _gsskrb5_inquire_names_for_mech ( } if (ret != GSS_S_COMPLETE) - gss_release_oid_set(NULL, name_types); + gss_release_oid_set(&tmp_status, name_types); return GSS_S_COMPLETE; }