VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Common/BootEncryption.cpp
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2017-06-11 17:26:42 +0200
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2017-06-11 17:28:22 +0200
commitce2aa639f448e4585e953fd14292dc0a9c5c4d86 (patch)
tree4a7433e75e0f9155ac1b2d9e7c753512064c76e8 /src/Common/BootEncryption.cpp
parent70d083bfb2c5dfb5537c5803aef5c8627c8cb551 (diff)
downloadVeraCrypt-ce2aa639f448e4585e953fd14292dc0a9c5c4d86.tar.gz
VeraCrypt-ce2aa639f448e4585e953fd14292dc0a9c5c4d86.zip
Windows: various fixes following Coverity analysis.
Diffstat (limited to 'src/Common/BootEncryption.cpp')
-rw-r--r--src/Common/BootEncryption.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Common/BootEncryption.cpp b/src/Common/BootEncryption.cpp
index 60985751..4e505eca 100644
--- a/src/Common/BootEncryption.cpp
+++ b/src/Common/BootEncryption.cpp
@@ -2137,6 +2137,7 @@ namespace VeraCrypt
ZeroMemory (&sdn, sizeof (sdn));
ZeroMemory (&partInfo, sizeof (partInfo));
m_bMounted = false;
+ bBootVolumePathSelected = false;
}
void EfiBoot::SelectBootVolumeESP() {
@@ -2161,14 +2162,14 @@ namespace VeraCrypt
PUNICODE_STRING pStr = (PUNICODE_STRING) tempBuf;
memcpy (BootVolumePath, pStr->Buffer, min (pStr->Length, (sizeof (BootVolumePath) - 2)));
- bBootVolumePathSelected = TRUE;
+ bBootVolumePathSelected = true;
}
void EfiBoot::SelectBootVolume(WCHAR* bootVolumePath) {
wstring str;
str = bootVolumePath;
memcpy (BootVolumePath, &str[0], min (str.length() * 2, (sizeof (BootVolumePath) - 2)));
- bBootVolumePathSelected = TRUE;
+ bBootVolumePathSelected = true;
}
void EfiBoot::MountBootPartition(WCHAR letter) {