[misc] fix VS2012 Code Analysis warnings

* Only for files that aren't part of external dependencies
* Also update copyright date
This commit is contained in:
Pete Batard 2013-01-09 21:54:28 +00:00
parent ae43dfd721
commit c4cb9d03c1
12 changed files with 76 additions and 38 deletions

View file

@ -180,7 +180,7 @@ BOOL GetDriveLabel(DWORD DriveIndex, char* letter, char** label)
strncpy(VolumeLabel, AutorunLabel, sizeof(VolumeLabel));
safe_free(AutorunLabel);
*label = VolumeLabel;
} else if (GetVolumeInformationW(wDrivePath, wVolumeLabel, sizeof(wVolumeLabel),
} else if (GetVolumeInformationW(wDrivePath, wVolumeLabel, ARRAYSIZE(wVolumeLabel),
NULL, NULL, NULL, NULL, 0) && *wVolumeLabel) {
wchar_to_utf8_no_alloc(wVolumeLabel, VolumeLabel, sizeof(VolumeLabel));
*label = VolumeLabel;