allocate enough memory
This commit is contained in:
@@ -186,7 +186,7 @@ _gss_ntlm_get_user_cred(const ntlm_name target_name,
|
|||||||
static int
|
static int
|
||||||
_gss_copy_cred(ntlm_cred from, ntlm_cred *to)
|
_gss_copy_cred(ntlm_cred from, ntlm_cred *to)
|
||||||
{
|
{
|
||||||
*to = calloc(1, sizeof(*to));
|
*to = calloc(1, sizeof(**to));
|
||||||
if (*to == NULL)
|
if (*to == NULL)
|
||||||
return ENOMEM;
|
return ENOMEM;
|
||||||
(*to)->username = strdup(from->username);
|
(*to)->username = strdup(from->username);
|
||||||
|
Reference in New Issue
Block a user