[ros-kernel] IOCTL output buffer length
vizzini at plasmic.com
Mon Nov 17 11:15:33 CET 2003
On Tue, 2003-11-04 at 14:26, Ge van Geldorp wrote:
> Can someone verify the attached patch? It's purpose is to use
> IoStatus.Information as the number of bytes to copy to the output buffer
> on an IOCTL, instead of the OutputBufferLength. This is in line with the
> article found here: http://www.cmkrnl.com/arc-ioctlbuf.html and also
> matches the behaviour expected by a third-party driver.
I don't know if you have committed this or not, but there is one corner
case to keep in mind. Some IRPs (notably a certain PnP IRP) use
IoStatus.Information for something other than the length of the return
value. The one I have in mind passes a pointer to a structure that the
PnP manager frees on return - this could/would cause an invalid free in
a properly-coded PnP manager.
Sorry for the late follow-up.
More information about the Ros-kernel