Removed IoGetCurrentIrpStackLocation from some functions.
authorHartmut Birr <osexpert@googlemail.com>
Mon, 21 Jan 2002 22:30:27 +0000 (22:30 +0000)
committerHartmut Birr <osexpert@googlemail.com>
Mon, 21 Jan 2002 22:30:27 +0000 (22:30 +0000)
svn path=/trunk/; revision=2537

reactos/ntoskrnl/io/cleanup.c
reactos/ntoskrnl/io/irp.c

index 6769ebf..2c6d3b3 100644 (file)
@@ -38,7 +38,7 @@ IopCompleteRequest1(struct _KAPC* Apc,
    Irp = (PIRP)(*SystemArgument1);
    PriorityBoost = (CCHAR)(LONG)(*SystemArgument2);
    
-   IoStack = IoGetCurrentIrpStackLocation(Irp);
+   IoStack = &Irp->Stack[(ULONG)Irp->CurrentLocation];
    
    (*SystemArgument1) = (PVOID)Irp->UserIosb;
    (*SystemArgument2) = (PVOID)Irp->IoStatus.Information;
@@ -174,8 +174,8 @@ VOID IoSecondStageCompletion(PIRP Irp, CCHAR PriorityBoost)
    DPRINT("IoSecondStageCompletion(Irp %x, PriorityBoost %d)\n",
          Irp, PriorityBoost);
    
-   IoStack = IoGetCurrentIrpStackLocation(Irp);
-   
+   IoStack = &Irp->Stack[(ULONG)Irp->CurrentLocation];
+
    DeviceObject = IoStack->DeviceObject;
    
    switch (IoStack->MajorFunction)
index 09f5915..7230ffc 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: irp.c,v 1.38 2001/08/27 01:20:50 ekohl Exp $
+/* $Id: irp.c,v 1.39 2002/01/21 22:30:26 hbirr Exp $
  *
  * COPYRIGHT:       See COPYING in the top level directory
  * PROJECT:         ReactOS kernel
@@ -53,7 +53,7 @@ IoFreeIrp (PIRP Irp)
  *      Irp = Irp to free
  */
 {
-   ExFreePool(Irp);
+       ExFreePool(Irp);
 }
 
 
@@ -90,7 +90,7 @@ IoInitializeIrp (PIRP Irp, USHORT PacketSize, CCHAR StackSize)
    Irp->Size = PacketSize;
    Irp->StackCount = StackSize;
    Irp->CurrentLocation = StackSize;
-   Irp->Tail.Overlay.CurrentStackLocation = IoGetCurrentIrpStackLocation(Irp);
+   Irp->Tail.Overlay.CurrentStackLocation = &Irp->Stack[(ULONG)StackSize];
 }