sorry,I am poor in English.
Now,I found when I write data to disk,the os is bluescreen.
the information on screen is:
STOP:0x0000044(0x859D8168 , 0x0000CCA ,0x0000000,0x000000)
MULTPLE_IRP_COMPLETE_REQUESTS.
----- Original Message -----
From: jackzdk
Newsgroups: ntfsd
To: xxxxx@lists.osr.com
Sent: Thursday, December 02, 2004 10:11 AM
Subject: write data in IRP_MJ_WRITE
hi,all
I am a new guy in driver programming.this is a part of my file system filter driver.
there is some wrong in my code. I think the information of buffer2 will be shown on monitor,but it doesn’t,buffer1 instead.
can anyone tell me waht is wrong ?
case IRP_MJ_WRITE:
if(Irp->MdlAddress)
buffer1 = MmGetSystemAddressForMdlSafe(Irp->MdlAddress , NormalPagePriority);
else
buffer1 = Irp->UserBuffer;
KeInitializeEvent( &waitEvent, SynchronizationEvent, FALSE );
IoCopyCurrentIrpStackLocationToNext( Irp );
IoSetCompletionRoutine( Irp,
&MyFilterCompletion,
&waitEvent,
TRUE,
TRUE,
TRUE );
status = IoCallDriver( MyExtension->NextDeviceObject, Irp );
if (STATUS_PENDING == status) {
NTSTATUS localStatus = KeWaitForSingleObject(
&waitEvent,
Executive,
KernelMode,
FALSE,
NULL);
ASSERT(STATUS_SUCCESS == localStatus);
}
// init buffer2.
…
RtlCopyMemory(buffer1,buffer2,Len);
…
status = Irp->IoStatus.Status;
IoCompleteRequest( Irp, IO_NO_INCREMENT );
return status;
thanks in advance.
??1.5G ȫ???ռ䡪???126??? http://www.126.com ???ע??>>>
???30?׳???ͣ???100???˹??רҵɱ???೬G???ܵ???飡