kdb-mspac: Fix out of bounds memset

This memset was harmless as the following data is then set again, but an
optimizing compiler might conceivably reorder instructions causing issues.

CoverityID: 11909

Fixes:
https://fedorahosted.org/freeipa/ticket/3883
This commit is contained in:
Simo Sorce
2013-08-27 09:24:32 -04:00
committed by Petr Viktorin
parent b29ce20705
commit f96257397e

View File

@@ -775,7 +775,7 @@ static krb5_error_code ipadb_fill_info3(struct ipadb_context *ipactx,
}
/* always zero out, not used for Krb, only NTLM */
memset(&info3->base.LMSessKey, '\0', sizeof(info3->base.key));
memset(&info3->base.LMSessKey, '\0', sizeof(info3->base.LMSessKey));
/* TODO: fill based on objectclass, user vs computer, etc... */
info3->base.acct_flags = ACB_NORMAL; /* samr_AcctFlags */