1
0
mirror of https://github.com/veracrypt/VeraCrypt.git synced 2025-11-11 19:08:26 -06:00

Windows: Avoid modifying BootArguments structure and use __unaligned keyword to inform compiler that pointer is unaligned.

This avoids issues with existing bootloaders
This commit is contained in:
Mounir IDRASSI
2024-11-16 01:50:06 +01:00
parent c86577fc0e
commit 9c9870b103
4 changed files with 4 additions and 5 deletions

View File

@@ -411,7 +411,7 @@ static void ComputeBootLoaderFingerprint(PDEVICE_OBJECT LowerDeviceObject, uint8
}
static NTSTATUS MountDrive (DriveFilterExtension *Extension, Password *password, uint32 *headerSaltCrc32)
static NTSTATUS MountDrive (DriveFilterExtension *Extension, Password *password, __unaligned uint32 *headerSaltCrc32)
{
BOOL hiddenVolume = (BootArgs.HiddenSystemPartitionStart != 0);
int64 hiddenHeaderOffset = BootArgs.HiddenSystemPartitionStart + TC_HIDDEN_VOLUME_HEADER_OFFSET;