mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 19:52:59 +00:00
[KERNEL32]: Whitespace fixes only, no functional code changes.
svn path=/trunk/; revision=71687
This commit is contained in:
parent
def1d69426
commit
5113536603
1 changed files with 181 additions and 196 deletions
|
@ -257,24 +257,19 @@ QueryDosDeviceA(
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Buffer = RtlAllocateHeap (RtlGetProcessHeap (),
|
Buffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, ucchMax * sizeof(WCHAR));
|
||||||
0,
|
|
||||||
ucchMax * sizeof(WCHAR));
|
|
||||||
if (Buffer == NULL)
|
if (Buffer == NULL)
|
||||||
{
|
{
|
||||||
if (lpDeviceName)
|
if (lpDeviceName)
|
||||||
{
|
{
|
||||||
RtlFreeHeap (RtlGetProcessHeap (),
|
RtlFreeHeap(RtlGetProcessHeap(), 0, DeviceNameU.Buffer);
|
||||||
0,
|
|
||||||
DeviceNameU.Buffer);
|
|
||||||
}
|
}
|
||||||
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
Length = QueryDosDeviceW(lpDeviceName ? DeviceNameU.Buffer : NULL,
|
Length = QueryDosDeviceW(lpDeviceName ? DeviceNameU.Buffer : NULL,
|
||||||
Buffer,
|
Buffer, ucchMax);
|
||||||
ucchMax);
|
|
||||||
if (Length != 0)
|
if (Length != 0)
|
||||||
{
|
{
|
||||||
TargetPathA.Buffer = lpTargetPath;
|
TargetPathA.Buffer = lpTargetPath;
|
||||||
|
@ -289,23 +284,17 @@ QueryDosDeviceA(
|
||||||
TargetPathA.Length = 0;
|
TargetPathA.Length = 0;
|
||||||
TargetPathA.MaximumLength = (USHORT)CurrentLength;
|
TargetPathA.MaximumLength = (USHORT)CurrentLength;
|
||||||
|
|
||||||
RtlUnicodeStringToAnsiString (&TargetPathA,
|
RtlUnicodeStringToAnsiString(&TargetPathA, &TargetPathU, FALSE);
|
||||||
&TargetPathU,
|
|
||||||
FALSE);
|
|
||||||
ucchMax -= CurrentLength;
|
ucchMax -= CurrentLength;
|
||||||
TargetPathA.Buffer += TargetPathA.Length;
|
TargetPathA.Buffer += TargetPathA.Length;
|
||||||
TargetPathU.Buffer += TargetPathU.Length / sizeof(WCHAR);
|
TargetPathU.Buffer += TargetPathU.Length / sizeof(WCHAR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlFreeHeap (RtlGetProcessHeap (),
|
RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer);
|
||||||
0,
|
|
||||||
Buffer);
|
|
||||||
if (lpDeviceName)
|
if (lpDeviceName)
|
||||||
{
|
{
|
||||||
RtlFreeHeap (RtlGetProcessHeap (),
|
RtlFreeHeap(RtlGetProcessHeap(), 0, DeviceNameU.Buffer);
|
||||||
0,
|
|
||||||
DeviceNameU.Buffer);
|
|
||||||
}
|
}
|
||||||
return Length;
|
return Length;
|
||||||
}
|
}
|
||||||
|
@ -337,8 +326,7 @@ QueryDosDeviceW(
|
||||||
PWSTR Ptr;
|
PWSTR Ptr;
|
||||||
|
|
||||||
/* Open the '\??' directory */
|
/* Open the '\??' directory */
|
||||||
RtlInitUnicodeString (&UnicodeString,
|
RtlInitUnicodeString(&UnicodeString, L"\\??");
|
||||||
L"\\??");
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -359,8 +347,7 @@ QueryDosDeviceW(
|
||||||
if (lpDeviceName != NULL)
|
if (lpDeviceName != NULL)
|
||||||
{
|
{
|
||||||
/* Open the lpDeviceName link object */
|
/* Open the lpDeviceName link object */
|
||||||
RtlInitUnicodeString (&UnicodeString,
|
RtlInitUnicodeString(&UnicodeString, (PWSTR)lpDeviceName);
|
||||||
(PWSTR)lpDeviceName);
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -459,9 +446,7 @@ QueryDosDeviceW(
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
memcpy (Ptr,
|
memcpy(Ptr, DirInfo->Name.Buffer, DirInfo->Name.Length);
|
||||||
DirInfo->Name.Buffer,
|
|
||||||
DirInfo->Name.Length);
|
|
||||||
Ptr += NameLength;
|
Ptr += NameLength;
|
||||||
Length += NameLength;
|
Length += NameLength;
|
||||||
*Ptr = UNICODE_NULL;
|
*Ptr = UNICODE_NULL;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue