diff options
Diffstat (limited to 'src/Core')
-rw-r--r-- | src/Core/CoreBase.cpp | 2 | ||||
-rw-r--r-- | src/Core/FatFormatter.cpp | 22 | ||||
-rw-r--r-- | src/Core/RandomNumberGenerator.cpp | 4 | ||||
-rw-r--r-- | src/Core/Unix/CoreService.cpp | 6 | ||||
-rw-r--r-- | src/Core/Unix/CoreUnix.cpp | 2 | ||||
-rw-r--r-- | src/Core/Unix/Linux/CoreLinux.cpp | 2 |
6 files changed, 19 insertions, 19 deletions
diff --git a/src/Core/CoreBase.cpp b/src/Core/CoreBase.cpp index c1016726..356d4348 100644 --- a/src/Core/CoreBase.cpp +++ b/src/Core/CoreBase.cpp @@ -144,7 +144,7 @@ namespace VeraCrypt outerVolume->ReadSectors (bootSectorBuffer, 0); int fatType; - byte *bootSector = bootSectorBuffer.Ptr(); + uint8 *bootSector = bootSectorBuffer.Ptr(); if (memcmp (bootSector + 54, "FAT12", 5) == 0) fatType = 12; diff --git a/src/Core/FatFormatter.cpp b/src/Core/FatFormatter.cpp index fa327837..c8115f9b 100644 --- a/src/Core/FatFormatter.cpp +++ b/src/Core/FatFormatter.cpp @@ -149,7 +149,7 @@ namespace VeraCrypt } } - static void PutBoot (fatparams * ft, byte *boot, uint32 volumeId) + static void PutBoot (fatparams * ft, uint8 *boot, uint32 volumeId) { int cnt = 0; @@ -244,7 +244,7 @@ namespace VeraCrypt /* FAT32 FSInfo */ - static void PutFSInfo (byte *sector, fatparams *ft) + static void PutFSInfo (uint8 *sector, fatparams *ft) { memset (sector, 0, ft->sector_size); sector[3] = 0x41; /* LeadSig */ @@ -294,16 +294,16 @@ namespace VeraCrypt sector.Zero(); uint32 volumeId; - RandomNumberGenerator::GetDataFast (BufferPtr ((byte *) &volumeId, sizeof (volumeId))); + RandomNumberGenerator::GetDataFast (BufferPtr ((uint8 *) &volumeId, sizeof (volumeId))); - PutBoot (ft, (byte *) sector, volumeId); + PutBoot (ft, (uint8 *) sector, volumeId); writeSector (sector); ++sectorNumber; /* fat32 boot area */ if (ft->size_fat == 32) { /* fsinfo */ - PutFSInfo((byte *) sector, ft); + PutFSInfo((uint8 *) sector, ft); writeSector (sector); ++sectorNumber; /* reserved */ @@ -317,10 +317,10 @@ namespace VeraCrypt /* bootsector backup */ sector.Zero(); - PutBoot (ft, (byte *) sector, volumeId); + PutBoot (ft, (uint8 *) sector, volumeId); writeSector (sector); ++sectorNumber; - PutFSInfo((byte *) sector, ft); + PutFSInfo((uint8 *) sector, ft); writeSector (sector); ++sectorNumber; } @@ -340,10 +340,10 @@ namespace VeraCrypt if (n == 0) { - byte fat_sig[12]; + uint8 fat_sig[12]; if (ft->size_fat == 32) { - fat_sig[0] = (byte) ft->media; + fat_sig[0] = (uint8) ft->media; fat_sig[1] = fat_sig[2] = 0xff; fat_sig[3] = 0x0f; fat_sig[4] = fat_sig[5] = fat_sig[6] = 0xff; @@ -354,7 +354,7 @@ namespace VeraCrypt } else if (ft->size_fat == 16) { - fat_sig[0] = (byte) ft->media; + fat_sig[0] = (uint8) ft->media; fat_sig[1] = 0xff; fat_sig[2] = 0xff; fat_sig[3] = 0xff; @@ -362,7 +362,7 @@ namespace VeraCrypt } else if (ft->size_fat == 12) { - fat_sig[0] = (byte) ft->media; + fat_sig[0] = (uint8) ft->media; fat_sig[1] = 0xff; fat_sig[2] = 0xff; fat_sig[3] = 0x00; diff --git a/src/Core/RandomNumberGenerator.cpp b/src/Core/RandomNumberGenerator.cpp index 3fb6062a..b60b4eed 100644 --- a/src/Core/RandomNumberGenerator.cpp +++ b/src/Core/RandomNumberGenerator.cpp @@ -114,7 +114,7 @@ namespace VeraCrypt ScopeLock lock (AccessMutex); size_t bufferLen = buffer.Size(), loopLen; - byte* pbBuffer = buffer.Get(); + uint8* pbBuffer = buffer.Get(); // Initialize JitterEntropy RNG for this call if (0 == jent_entropy_init ()) @@ -267,7 +267,7 @@ namespace VeraCrypt Buffer buffer (1); for (size_t i = 0; i < PoolSize * 10; ++i) { - buffer[0] = (byte) i; + buffer[0] = (uint8) i; AddToPool (buffer); } diff --git a/src/Core/Unix/CoreService.cpp b/src/Core/Unix/CoreService.cpp index e3fca20e..6d0f05e5 100644 --- a/src/Core/Unix/CoreService.cpp +++ b/src/Core/Unix/CoreService.cpp @@ -57,7 +57,7 @@ namespace VeraCrypt // Wait for sync code while (true) { - byte b; + uint8 b; throw_sys_if (read (STDIN_FILENO, &b, 1) != 1); if (b != 0x00) continue; @@ -543,7 +543,7 @@ namespace VeraCrypt try { - shared_ptr <Stream> stream (new MemoryStream (ConstBufferPtr ((byte *) &errOutput[0], errOutput.size()))); + shared_ptr <Stream> stream (new MemoryStream (ConstBufferPtr ((uint8 *) &errOutput[0], errOutput.size()))); deserializedObject.reset (Serializable::DeserializeNew (stream)); deserializedException = dynamic_cast <Exception*> (deserializedObject.get()); } @@ -575,7 +575,7 @@ namespace VeraCrypt ServiceOutputStream = shared_ptr <Stream> (new FileStream (outPipe->GetReadFD())); // Send sync code - byte sync[] = { 0, 0x11, 0x22 }; + uint8 sync[] = { 0, 0x11, 0x22 }; ServiceInputStream->Write (ConstBufferPtr (sync, array_capacity (sync))); AdminInputPipe = move_ptr(inPipe); diff --git a/src/Core/Unix/CoreUnix.cpp b/src/Core/Unix/CoreUnix.cpp index 258979b9..26076a28 100644 --- a/src/Core/Unix/CoreUnix.cpp +++ b/src/Core/Unix/CoreUnix.cpp @@ -241,7 +241,7 @@ namespace VeraCrypt device.SeekAt (0); device.ReadCompleteBuffer (bootSector); - byte *b = bootSector.Ptr(); + uint8 *b = bootSector.Ptr(); return memcmp (b + 3, "NTFS", 4) != 0 && memcmp (b + 54, "FAT", 3) != 0 diff --git a/src/Core/Unix/Linux/CoreLinux.cpp b/src/Core/Unix/Linux/CoreLinux.cpp index 5d5ba38f..cd4be80f 100644 --- a/src/Core/Unix/Linux/CoreLinux.cpp +++ b/src/Core/Unix/Linux/CoreLinux.cpp @@ -386,7 +386,7 @@ namespace VeraCrypt dmCreateArgs << nativeDevPath << " 0"; SecureBuffer dmCreateArgsBuf (dmCreateArgs.str().size()); - dmCreateArgsBuf.CopyFrom (ConstBufferPtr ((byte *) dmCreateArgs.str().c_str(), dmCreateArgs.str().size())); + dmCreateArgsBuf.CopyFrom (ConstBufferPtr ((uint8 *) dmCreateArgs.str().c_str(), dmCreateArgs.str().size())); // Keys const SecureBuffer &cipherKey = cipher.GetKey(); |