Static Code Analysis : fix usage of strncpy and sscanf.

This commit is contained in:
Mounir IDRASSI committed 2014-11-08 23:20:45 +01:00
1 parent 899a22b840
commit 9d027b02b9
3 files changed
+8 -8

No files matched your search

+1 -1
View File
@@ -1699,7 +1699,7 @@ static BOOL GetDevicePathForHiddenOS (void)
try
{
strncpy (szFileName, BootEncObj->GetPartitionForHiddenOS().DevicePath.c_str(), sizeof(szFileName));
strncpy (szFileName, BootEncObj->GetPartitionForHiddenOS().DevicePath.c_str(), sizeof(szFileName) - 1);
CreateFullVolumePath (szDiskFile, szFileName, &tmpbDevice);
}