VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2014-12-17 12:09:25 +0100
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2014-12-17 12:14:59 +0100
commitc98400a2b7f035b6873480889b701380b66853a2 (patch)
treef71fb03432421ca2214f3d401197f989aef8f196 /src
parent5b151492bd5c33d58ae99103ddfda3d32b183fc9 (diff)
downloadVeraCrypt-c98400a2b7f035b6873480889b701380b66853a2.tar.gz
VeraCrypt-c98400a2b7f035b6873480889b701380b66853a2.zip
Windows: in silent mode, don't show the wait dialog during mount operation
Diffstat (limited to 'src')
-rw-r--r--src/Common/Dlgcode.c26
1 files changed, 17 insertions, 9 deletions
diff --git a/src/Common/Dlgcode.c b/src/Common/Dlgcode.c
index 1dbbbd29..0105de4f 100644
--- a/src/Common/Dlgcode.c
+++ b/src/Common/Dlgcode.c
@@ -6363,15 +6363,23 @@ retry:
mount.bPartitionInInactiveSysEncScope = TRUE;
}
- MountThreadParam threadParam;
- threadParam.hwnd = hwndDlg;
- threadParam.pmount = &mount;
- threadParam.pbResult = &bResult;
- threadParam.pdwResult = &dwResult;
-
- DialogBoxParamW (hInst,
- MAKEINTRESOURCEW (IDD_STATIC_MODAL_WAIT_DLG), hwndDlg,
- (DLGPROC) MountWaitDlgProc, (LPARAM) &threadParam);
+ if (!quiet)
+ {
+ MountThreadParam threadParam;
+ threadParam.hwnd = hwndDlg;
+ threadParam.pmount = &mount;
+ threadParam.pbResult = &bResult;
+ threadParam.pdwResult = &dwResult;
+
+ DialogBoxParamW (hInst,
+ MAKEINTRESOURCEW (IDD_STATIC_MODAL_WAIT_DLG), hwndDlg,
+ (DLGPROC) MountWaitDlgProc, (LPARAM) &threadParam);
+ }
+ else
+ {
+ bResult = DeviceIoControl (hDriver, TC_IOCTL_MOUNT_VOLUME, &mount,
+ sizeof (mount), &mount, sizeof (mount), &dwResult, NULL);
+ }
burn (&mount.VolumePassword, sizeof (mount.VolumePassword));
burn (&mount.ProtectedHidVolPassword, sizeof (mount.ProtectedHidVolPassword));