Fixed warnings.

svn path=/trunk/; revision=3827
This commit is contained in:
Eric Kohl 2002-12-06 17:33:16 +00:00
parent 5c0db541d3
commit 72136233fb

View file

@ -1,4 +1,4 @@
/* $Id: volume.c,v 1.26 2002/09/08 10:22:42 chorns Exp $
/* $Id: volume.c,v 1.27 2002/12/06 17:33:16 ekohl Exp $
*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS system libraries
@ -30,7 +30,10 @@
#define MAX_DOS_DRIVES 26
HANDLE InternalOpenDirW(PWCHAR DirName, BOOLEAN Write)
static HANDLE
InternalOpenDirW(LPCWSTR DirName,
BOOLEAN Write)
{
UNICODE_STRING NtPathU;
OBJECT_ATTRIBUTES ObjectAttributes;
@ -38,7 +41,7 @@ HANDLE InternalOpenDirW(PWCHAR DirName, BOOLEAN Write)
IO_STATUS_BLOCK IoStatusBlock;
HANDLE hFile;
if (!RtlDosPathNameToNtPathName_U ((LPWSTR)DirName,
if (!RtlDosPathNameToNtPathName_U((LPWSTR)DirName,
&NtPathU,
NULL,
NULL))
@ -76,6 +79,7 @@ HANDLE InternalOpenDirW(PWCHAR DirName, BOOLEAN Write)
return hFile;
}
DWORD STDCALL
GetLogicalDriveStringsA(DWORD nBufferLength,
LPSTR lpBuffer)
@ -223,12 +227,12 @@ GetDiskFreeSpaceW(
RootPathName[3] = 0;
}
if (INVALID_HANDLE_VALUE == (hFile = InternalOpenDirW((PWCHAR)lpRootPathName, FALSE)))
hFile = InternalOpenDirW(lpRootPathName, FALSE);
if (INVALID_HANDLE_VALUE == hFile)
{
return FALSE;
}
errCode = NtQueryVolumeInformationFile(hFile,
&IoStatusBlock,
&FileFsSize,
@ -322,7 +326,8 @@ GetDiskFreeSpaceExW(
RootPathName[3] = 0;
}
if (INVALID_HANDLE_VALUE == (hFile = InternalOpenDirW(lpDirectoryName, FALSE)))
hFile = InternalOpenDirW(lpDirectoryName, FALSE);
if (INVALID_HANDLE_VALUE == hFile)
{
return FALSE;
}
@ -678,7 +683,8 @@ SetVolumeLabelW(LPCWSTR lpRootPathName,
wcscpy(LabelInfo->VolumeLabel,
lpVolumeName);
if (INVALID_HANDLE_VALUE == (hFile = InternalOpenDirW(lpRootPathName, TRUE)))
hFile = InternalOpenDirW(lpRootPathName, TRUE);
if (INVALID_HANDLE_VALUE == hFile)
{
return FALSE;
}