mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
mkimg: zero entry in vhdx_write_metadata
Otherwise _reserved might contain uninitialized data. MFC after: 1 week Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
438fd19dc3
commit
036af1053a
1 changed files with 1 additions and 0 deletions
|
|
@ -331,6 +331,7 @@ vhdx_write_metadata(int fd, uint64_t image_size)
|
|||
memset(metadata, 0, SIZE_1MB);
|
||||
|
||||
memset(&header, 0, sizeof(header));
|
||||
memset(&entry, 0, sizeof(entry));
|
||||
|
||||
le64enc(&header.signature, VHDX_METADATA_TABLE_HEADER_SIGNATURE);
|
||||
le16enc(&header.entry_count, 5);
|
||||
|
|
|
|||
Loading…
Reference in a new issue