1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-28 07:21:54 +03:00

r14092: Fix coverity bug #22. Ensure no possible null

deref.
Jeremy.
This commit is contained in:
Jeremy Allison 2006-03-09 19:51:38 +00:00 committed by Gerald (Jerry) Carter
parent 76c4d5212b
commit 0026fb0b28

View File

@ -5633,7 +5633,11 @@ void init_sam_user_info23A(SAM_USER_INFO_23 * usr, NTTIME * logon_time, /* all z
data_blob_free(&blob);
memcpy(&usr->logon_hrs, hrs, sizeof(usr->logon_hrs));
if (hrs) {
memcpy(&usr->logon_hrs, hrs, sizeof(usr->logon_hrs));
} else {
ZERO_STRUCT(usr->logon_hrs);
}
}
/*******************************************************************