mirror of
https://github.com/reactos/reactos.git
synced 2025-08-04 23:25:45 +00:00
Fix checking of return values from IoCreateDevice. Spotted by R.T.Sivakumar <rtshiva@gmail.com>.
svn path=/trunk/; revision=33448
This commit is contained in:
parent
76256a1bdd
commit
b512080393
1 changed files with 19 additions and 17 deletions
|
@ -56,8 +56,7 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
0,
|
0,
|
||||||
FALSE,
|
FALSE,
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
if (!NT_SUCCESS(Status))
|
|
||||||
{
|
|
||||||
if (Status == STATUS_OBJECT_NAME_EXISTS ||
|
if (Status == STATUS_OBJECT_NAME_EXISTS ||
|
||||||
Status == STATUS_OBJECT_NAME_COLLISION)
|
Status == STATUS_OBJECT_NAME_COLLISION)
|
||||||
{
|
{
|
||||||
|
@ -70,12 +69,15 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
0,
|
0,
|
||||||
FALSE,
|
FALSE,
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
return (Status);
|
return (Status);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
VfatGlobalData = DeviceObject->DeviceExtension;
|
VfatGlobalData = DeviceObject->DeviceExtension;
|
||||||
RtlZeroMemory (VfatGlobalData, sizeof(VFAT_GLOBAL_DATA));
|
RtlZeroMemory (VfatGlobalData, sizeof(VFAT_GLOBAL_DATA));
|
||||||
VfatGlobalData->DriverObject = DriverObject;
|
VfatGlobalData->DriverObject = DriverObject;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue