You are not done – you must also call FltParseFileNameInformation. Try this:
status = FltGetFileNameInformation( Data, FLT_FILE_NAME_NORMALIZED | FLT_FILE_NAME_QUERY_DEFAULT, &pFLT );
if( !NT_SUCCESS( status ) )
return FLT_PREOP_SUCCESS_NO_CALLBACK;
status = FltParseFileNameInformation( pFLT );
if( !NT_SUCCESS( status ) )
{
FltReleaseFileNameInformation( pFLT );
return FLT_PREOP_SUCCESS_NO_CALLBACK;
}
DoTraceMessage( DEBUG_ANY, “%!FUNC! File name %wZ”, &pFLT->Name );
Ken
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Thursday, May 17, 2007 9:26 PM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] minifilter FltGetFileNameinfomation
I use minifilter “passthrough.c” to filter CREATE IRP,
in “PtPreOperationCreate”, i want to get filename,so i write code:
PFILE_OBJECT FileObject = FltObjects->FileObject;
KdPrint( (“%ws”, FileObject->FileName.Buffer) );
…
i open debugView.exe, it’s run well
/*******************************************/
i write code instead:
FltGetFileNameInformation( Data, FLT_FILE_NAME_NORMALIZED, &pFLT );
KdPrint( (“%ws”, pFlt->Name.Buffer) );
…
when i open debugView.exe, show BSOD, information is about NOPAGE area happend PAGE error, i try KdPrint( (“%x”,
&FileObject->FileName.Buffer) ), the error is countine,i get the FileObject address is 0xffxxxxxx
please tell me why? thank you:)
Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17
You are currently subscribed to ntfsd as: xxxxx@comcast.net
To unsubscribe send a blank email to xxxxx@lists.osr.com