Skip to content

Commit

Permalink
Make sure to free also the remote ctx struct
Browse files Browse the repository at this point in the history
The xdr_free() call only frees the contents and not the containing
structure itself.

Signed-off-by: Simo Sorce <simo@redhat.com>
Reviewed-by: Robbie Harwood <rharwood@redhat.com>
  • Loading branch information
simo5 authored and frozencemetery committed Sep 2, 2020
1 parent 447d535 commit e681134
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/client/gpm_release_handle.c
Expand Up @@ -106,5 +106,7 @@ OM_uint32 gpm_delete_sec_context(OM_uint32 *minor_status,
gpm_free_xdrs(GSSX_RELEASE_HANDLE, &uarg, &ures);
done:
xdr_free((xdrproc_t)xdr_gssx_ctx, (char *)r);
free(r);
*context_handle = NULL;
return ret;
}

0 comments on commit e681134

Please sign in to comment.