[ros-diffs] [cwittich] 30597: use ExAllocatePoolWithTag instead of ExAllocatePool

cwittich at svn.reactos.org cwittich at svn.reactos.org
Tue Nov 20 16:26:17 CET 2007


Author: cwittich
Date: Tue Nov 20 18:26:17 2007
New Revision: 30597

URL: http://svn.reactos.org/svn/reactos?rev=30597&view=rev
Log:
use ExAllocatePoolWithTag instead of ExAllocatePool

Modified:
    trunk/reactos/drivers/filesystems/vfat/create.c
    trunk/reactos/drivers/filesystems/vfat/dir.c
    trunk/reactos/drivers/filesystems/vfat/dirwr.c
    trunk/reactos/drivers/filesystems/vfat/fsctl.c
    trunk/reactos/drivers/filesystems/vfat/vfat.h

Modified: trunk/reactos/drivers/filesystems/vfat/create.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/create.c?rev=30597&r1=30596&r2=30597&view=diff
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/create.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/create.c Tue Nov 20 18:26:17 2007
@@ -201,7 +201,7 @@
 	DPRINT ("FindFile: Path %wZ)\n",&Parent->PathNameU);
 
 	PathNameBufferLength = LONGNAME_MAX_LENGTH * sizeof(WCHAR);
-	PathNameBuffer = ExAllocatePool(NonPagedPool, PathNameBufferLength + sizeof(WCHAR));
+	PathNameBuffer = ExAllocatePoolWithTag(NonPagedPool, PathNameBufferLength + sizeof(WCHAR), TAG_VFAT);
 	if (!PathNameBuffer)
 	{
 		CHECKPOINT1;

Modified: trunk/reactos/drivers/filesystems/vfat/dir.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/dir.c?rev=30597&r1=30596&r2=30597&view=diff
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/dir.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/dir.c Tue Nov 20 18:26:17 2007
@@ -351,7 +351,7 @@
         {
           FirstQuery = TRUE;
           pCcb->SearchPattern.MaximumLength = pSearchPattern->Length + sizeof(WCHAR);
-          pCcb->SearchPattern.Buffer = ExAllocatePool(NonPagedPool, pCcb->SearchPattern.MaximumLength);
+          pCcb->SearchPattern.Buffer = ExAllocatePoolWithTag(NonPagedPool, pCcb->SearchPattern.MaximumLength, TAG_VFAT);
           if (!pCcb->SearchPattern.Buffer)
             {
               ExReleaseResourceLite(&pFcb->MainResource);
@@ -365,7 +365,7 @@
     {
       FirstQuery = TRUE;
       pCcb->SearchPattern.MaximumLength = 2 * sizeof(WCHAR);
-      pCcb->SearchPattern.Buffer = ExAllocatePool(NonPagedPool, 2 * sizeof(WCHAR));
+      pCcb->SearchPattern.Buffer = ExAllocatePoolWithTag(NonPagedPool, 2 * sizeof(WCHAR), TAG_VFAT);
       if (!pCcb->SearchPattern.Buffer)
         {
           ExReleaseResourceLite(&pFcb->MainResource);

Modified: trunk/reactos/drivers/filesystems/vfat/dirwr.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/dirwr.c?rev=30597&r1=30596&r2=30597&view=diff
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/dirwr.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/dirwr.c Tue Nov 20 18:26:17 2007
@@ -219,7 +219,7 @@
 
   nbSlots = (DirContext.LongNameU.Length / sizeof(WCHAR) + 12) / 13 + 1;	//nb of entry needed for long name+normal entry
   DPRINT ("NameLen= %d, nbSlots =%d\n", DirContext.LongNameU.Length / sizeof(WCHAR), nbSlots);
-  Buffer = ExAllocatePool (NonPagedPool, (nbSlots - 1) * sizeof (FAT_DIR_ENTRY));
+  Buffer = ExAllocatePoolWithTag (NonPagedPool, (nbSlots - 1) * sizeof (FAT_DIR_ENTRY), TAG_VFAT);
   if (Buffer == NULL)
   {
     return STATUS_INSUFFICIENT_RESOURCES;

Modified: trunk/reactos/drivers/filesystems/vfat/fsctl.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/fsctl.c?rev=30597&r1=30596&r2=30597&view=diff
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/fsctl.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/fsctl.c Tue Nov 20 18:26:17 2007
@@ -133,7 +133,7 @@
    if (*RecognizedFS)
    {
 
-      Boot = ExAllocatePool(NonPagedPool, DiskGeometry.BytesPerSector);
+      Boot = ExAllocatePoolWithTag(NonPagedPool, DiskGeometry.BytesPerSector, TAG_VFAT);
       if (Boot == NULL)
       {
          return STATUS_INSUFFICIENT_RESOURCES;
@@ -257,7 +257,7 @@
 
    if (!*RecognizedFS && PartitionInfoIsValid)
    {
-      BootFatX = ExAllocatePool(NonPagedPool, sizeof(struct _BootSectorFatX));
+      BootFatX = ExAllocatePoolWithTag(NonPagedPool, sizeof(struct _BootSectorFatX), TAG_VFAT);
       if (BootFatX == NULL)
       {
          *RecognizedFS=FALSE;

Modified: trunk/reactos/drivers/filesystems/vfat/vfat.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/vfat.h?rev=30597&r1=30596&r2=30597&view=diff
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/vfat.h (original)
+++ trunk/reactos/drivers/filesystems/vfat/vfat.h Tue Nov 20 18:26:17 2007
@@ -413,6 +413,7 @@
 #define TAG_CCB TAG('V', 'C', 'C', 'B')
 #define TAG_FCB TAG('V', 'F', 'C', 'B')
 #define TAG_IRP TAG('V', 'I', 'R', 'P')
+#define TAG_VFAT TAG('V', 'F', 'A', 'T')
 
 #define ENTRIES_PER_SECTOR (BLOCKSIZE / sizeof(FATDirEntry))
 




More information about the Ros-diffs mailing list