VirtualBox

Ignore:
Timestamp:
Sep 13, 2007 3:39:28 PM (17 years ago)
Author:
vboxsync
Message:

NT4 does not have Ex*PoolWithTag.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/VBoxGuest/VBoxGuest.cpp

    r4686 r4777  
    3434#include <VBox/VBoxGuestLib.h>
    3535#include <VBoxGuestInternal.h>
     36
     37#ifdef TARGET_NT4
     38/* XP DDK #defines ExFreePool to ExFreePoolWithTag. The latter does not exist on NT4, so...
     39 * The same for ExAllocatePool.
     40 */
     41#undef ExAllocatePool
     42#undef ExFreePool
     43#endif
    3644
    3745/*******************************************************************************
     
    478486#else
    479487            PVOID pvBalloon;
    480             pvBalloon = ExAllocatePoolWithTag(PagedPool, VMMDEV_MEMORY_BALLOON_CHUNK_SIZE, 'MBAL');
     488            pvBalloon = ExAllocatePool(PagedPool, VMMDEV_MEMORY_BALLOON_CHUNK_SIZE);
    481489            if (!pvBalloon)
    482490            {
     
    489497            {
    490498                rc = VERR_NO_MEMORY;
    491                 ExFreePoolWithTag(pvBalloon, 'MBAL');
     499                ExFreePool(pvBalloon);
    492500                AssertMsgFailed(("IoAllocateMdl %VGv %x failed!!\n", pvBalloon, VMMDEV_MEMORY_BALLOON_CHUNK_SIZE));
    493501                goto end;
     
    504512                    rc = VERR_NO_MEMORY;
    505513                    IoFreeMdl (pMdl);
    506                     ExFreePoolWithTag(pvBalloon, 'MBAL');
     514                    ExFreePool(pvBalloon);
    507515                    goto end;
    508516                }
     
    531539#else
    532540                IoFreeMdl (pMdl);
    533                 ExFreePoolWithTag(pvBalloon, 'MBAL');
     541                ExFreePool(pvBalloon);
    534542#endif
    535543                goto end;
     
    588596                MmUnlockPages (pMdl);
    589597                IoFreeMdl (pMdl);
    590                 ExFreePoolWithTag(pvBalloon, 'MBAL');
     598                ExFreePool(pvBalloon);
    591599#endif
    592600
     
    628636            {
    629637                pDevExt->MemBalloon.cMaxBalloons = req->u32PhysMemSize;
    630                 pDevExt->MemBalloon.paMdlMemBalloon = (PMDL *)ExAllocatePoolWithTag(PagedPool, req->u32PhysMemSize * sizeof(PMDL), 'MBAL');
     638                pDevExt->MemBalloon.paMdlMemBalloon = (PMDL *)ExAllocatePool(PagedPool, req->u32PhysMemSize * sizeof(PMDL));
    631639                Assert(pDevExt->MemBalloon.paMdlMemBalloon);
    632640                if (!pDevExt->MemBalloon.paMdlMemBalloon)
     
    670678        /* Clean up the memory balloon leftovers */
    671679        VBoxGuestSetBalloonSize(pDevExt, 0);
    672         ExFreePoolWithTag(pDevExt->MemBalloon.paMdlMemBalloon, 'MBAL');
     680        ExFreePool(pDevExt->MemBalloon.paMdlMemBalloon);
    673681        pDevExt->MemBalloon.paMdlMemBalloon = NULL;
    674682    }
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette