Skip to content
Snippets Groups Projects
Commit 40179bed authored by Frédéric Delanoy's avatar Frédéric Delanoy Committed by Alexandre Julliard
Browse files

shell32: Avoid hardcoding array lengths.

parent c55db752
No related branches found
No related tags found
No related merge requests found
......@@ -2115,7 +2115,7 @@ static HRESULT ShellLink_SetAdvertiseInfo(IShellLinkImpl *This, LPCWSTR str)
static BOOL ShellLink_GetVolumeInfo(LPCWSTR path, volume_info *volume)
{
const int label_sz = sizeof volume->label/sizeof volume->label[0];
WCHAR drive[4] = { path[0], ':', '\\', 0 };
WCHAR drive[] = { path[0], ':', '\\', 0 };
BOOL r;
volume->type = GetDriveTypeW(drive);
......
......@@ -1609,7 +1609,7 @@ static HRESULT WINAPI UnixFolder_IPersistFolder3_Initialize(IPersistFolder3* ifa
if (current->mkid.cb) {
if (_ILIsDrive(current)) {
WCHAR wszDrive[4] = { '?', ':', '\\', 0 };
WCHAR wszDrive[] = { '?', ':', '\\', 0 };
wszDrive[0] = (WCHAR)*_ILGetTextPointer(current);
if (!UNIXFS_get_unix_path(wszDrive, szBasePath))
return E_FAIL;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment