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

Windows: Add various checks to address Coverity reported issues.

This commit is contained in:
Mounir IDRASSI
2022-03-26 20:03:19 +01:00
parent a0809fe85c
commit 762065917f
11 changed files with 105 additions and 28 deletions

View File

@@ -442,6 +442,12 @@ int ExtendFileSystem (HWND hwndDlg , wchar_t *lpszVolume, Password *pVolumePassw
goto error;
}
if ((BytesPerSector == 0) || (BytesPerSector > (DWORD)INT_MAX))
{
nStatus = ERR_SECTOR_SIZE_INCOMPATIBLE;
goto error;
}
DebugAddProgressDlgStatus (hwndDlg, L"Extending file system ...\r\n");
// extend volume