From: David F. on
Hi,

Is there a way to get the size of a buffer allocated with
ExAllocatePoolWithTag without having to put your own wrapper around it.
Just native support?

TIA!!


From: Don Burn on
Why in the world would you want this? Either your driver allocated the
buffer and should know its size, or the buffer was passed to you with a
size. Any other case is bad design, for instance you should not be playing
with buffers you don't own, and you should not assume anything about the
size of a buffer passed to you beyond what the caller provides.


--
Don Burn (MVP, Windows DKD)
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply



"David F." <df2705(a)community.nospam> wrote in message
news:56A551A3-E716-4B32-9E98-65708308927A(a)microsoft.com...
> Hi,
>
> Is there a way to get the size of a buffer allocated with
> ExAllocatePoolWithTag without having to put your own wrapper around it.
> Just native support?
>
> TIA!!
>
>
>
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4713 (20091223) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>



__________ Information from ESET NOD32 Antivirus, version of virus signature database 4713 (20091223) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com




From: David F. on
realloc override without having to have #if defined(WIN_DDK_BUILD) around
sections of code that is universal.

"Don Burn" <burn(a)stopspam.windrvr.com> wrote in message
news:ezH4AVAhKHA.5380(a)TK2MSFTNGP06.phx.gbl...
> Why in the world would you want this? Either your driver allocated the
> buffer and should know its size, or the buffer was passed to you with a
> size. Any other case is bad design, for instance you should not be
> playing with buffers you don't own, and you should not assume anything
> about the size of a buffer passed to you beyond what the caller provides.
>
>
> --
> Don Burn (MVP, Windows DKD)
> Windows Filesystem and Driver Consulting
> Website: http://www.windrvr.com
> Blog: http://msmvps.com/blogs/WinDrvr
> Remove StopSpam to reply
>
>
>
> "David F." <df2705(a)community.nospam> wrote in message
> news:56A551A3-E716-4B32-9E98-65708308927A(a)microsoft.com...
>> Hi,
>>
>> Is there a way to get the size of a buffer allocated with
>> ExAllocatePoolWithTag without having to put your own wrapper around it.
>> Just native support?
>>
>> TIA!!
>>
>>
>>
>> __________ Information from ESET NOD32 Antivirus, version of virus
>> signature database 4713 (20091223) __________
>>
>> The message was checked by ESET NOD32 Antivirus.
>>
>> http://www.eset.com
>>
>>
>>
>
>
>
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4713 (20091223) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>
>
>

From: Scott Noone on
You're on your own on this one, we don't have that kind of insight into the
pool allocator in kernel mode.

-scott

--
Scott Noone
Consulting Associate
OSR Open Systems Resources, Inc.
http://www.osronline.com


"David F." <df2705(a)community.nospam> wrote in message
news:36DEBF22-9060-460C-879F-0DFAC256F38E(a)microsoft.com...
> realloc override without having to have #if defined(WIN_DDK_BUILD) around
> sections of code that is universal.
>
> "Don Burn" <burn(a)stopspam.windrvr.com> wrote in message
> news:ezH4AVAhKHA.5380(a)TK2MSFTNGP06.phx.gbl...
>> Why in the world would you want this? Either your driver allocated the
>> buffer and should know its size, or the buffer was passed to you with a
>> size. Any other case is bad design, for instance you should not be
>> playing with buffers you don't own, and you should not assume anything
>> about the size of a buffer passed to you beyond what the caller provides.
>>
>>
>> --
>> Don Burn (MVP, Windows DKD)
>> Windows Filesystem and Driver Consulting
>> Website: http://www.windrvr.com
>> Blog: http://msmvps.com/blogs/WinDrvr
>> Remove StopSpam to reply
>>
>>
>>
>> "David F." <df2705(a)community.nospam> wrote in message
>> news:56A551A3-E716-4B32-9E98-65708308927A(a)microsoft.com...
>>> Hi,
>>>
>>> Is there a way to get the size of a buffer allocated with
>>> ExAllocatePoolWithTag without having to put your own wrapper around it.
>>> Just native support?
>>>
>>> TIA!!
>>>
>>>
>>>
>>> __________ Information from ESET NOD32 Antivirus, version of virus
>>> signature database 4713 (20091223) __________
>>>
>>> The message was checked by ESET NOD32 Antivirus.
>>>
>>> http://www.eset.com
>>>
>>>
>>>
>>
>>
>>
>> __________ Information from ESET NOD32 Antivirus, version of virus
>> signature database 4713 (20091223) __________
>>
>> The message was checked by ESET NOD32 Antivirus.
>>
>> http://www.eset.com
>>
>>
>>
>>
>>
>
From: Pavel A. on
"David F." <df2705(a)community.nospam> wrote in message
news:36DEBF22-9060-460C-879F-0DFAC256F38E(a)microsoft.com...
> realloc override without having to have #if defined(WIN_DDK_BUILD) around
> sections of code that is universal.

Make your own allocator, or change design.
--pa


> "Don Burn" <burn(a)stopspam.windrvr.com> wrote in message
> news:ezH4AVAhKHA.5380(a)TK2MSFTNGP06.phx.gbl...
>> Why in the world would you want this? Either your driver allocated the
>> buffer and should know its size, or the buffer was passed to you with a
>> size. Any other case is bad design, for instance you should not be
>> playing with buffers you don't own, and you should not assume anything
>> about the size of a buffer passed to you beyond what the caller provides.
>>
>> --
>> Don Burn (MVP, Windows DKD)
>> Windows Filesystem and Driver Consulting
>> Website: http://www.windrvr.com
>> Blog: http://msmvps.com/blogs/WinDrvr
>> Remove StopSpam to reply
>>
>>
>>
>> "David F." <df2705(a)community.nospam> wrote in message
>> news:56A551A3-E716-4B32-9E98-65708308927A(a)microsoft.com...
>>> Hi,
>>>
>>> Is there a way to get the size of a buffer allocated with
>>> ExAllocatePoolWithTag without having to put your own wrapper around it.
>>> Just native support?
>>>
>>> TIA!!
>>>