23 #define BugCheckFileId (CDFS_BUG_CHECK_WRITE) 38 #define SafeZeroMemory(IC,AT,BYTE_COUNT) { \ 40 RtlZeroMemory( (AT), (BYTE_COUNT) ); \ 41 __pragma(warning(suppress: 6320)) \ 42 } _SEH2_EXCEPT( EXCEPTION_EXECUTE_HANDLER ) { \ 43 CdRaiseStatus( IC, STATUS_INVALID_USER_BUFFER ); \ 47 #define SafeZeroMemory(IC,AT,BYTE_COUNT) { \ 49 RtlZeroMemory( (AT), (BYTE_COUNT) ); \ 50 } _SEH2_EXCEPT( EXCEPTION_EXECUTE_HANDLER ) { \ 51 CdRaiseStatus( IC, STATUS_INVALID_USER_BUFFER ); \ 57 #pragma alloc_text(PAGE, CdCommonWrite) 102 ULONG WriteByteCount;
103 ULONG OriginalByteCount;
192 if (ByteRange >
Fcb->FileSize.QuadPart) {
195 ByteRange =
Fcb->FileSize.QuadPart;
210 (WriteByteCount > OriginalByteCount)) {
230 if (IrpContext->IoContext ==
NULL ||
240 IrpContext->IoContext = &LocalIoContext;
257 IrpContext->IoContext->AllocatedContext =
269 IrpContext->IoContext->Resource =
Fcb->Resource;
270 IrpContext->IoContext->RequestedByteCount =
ByteCount;
273 Irp->IoStatus.Information = WriteByteCount;
317 Irp->IoStatus.Information = 0;
334 }
else if (WriteByteCount !=
ByteCount) {
376 Status = CdFsdPostRequest( IrpContext,
Irp );
#define ExGetCurrentResourceThread()
#define IRP_CONTEXT_FLAG_WAIT
#define Add2Ptr(PTR, INC)
#define CCB_FLAG_DISMOUNT_ON_CLOSE
_In_ PFCB _In_ LONGLONG StartingOffset
#define IRP_CONTEXT_FLAG_ALLOC_IO
#define CdReleaseFile(IC, F)
#define BooleanFlagOn(F, SF)
_In_ WDFDPC _In_ BOOLEAN Wait
#define CCB_FLAG_ALLOW_EXTENDED_DASD_IO
#define CdMapUserBuffer(IC, UB)
#define IoIsErrorUserInduced(Status)
#define STATUS_INVALID_DEVICE_REQUEST
#define CdAcquireFileShared(IC, F)
#define STATUS_END_OF_FILE
#define FO_SYNCHRONOUS_IO
_Inout_ PFILE_OBJECT _In_ TYPE_OF_OPEN TypeOfOpen
#define _Analysis_suppress_lock_checking_(lock)
VOID CdCompleteRequest(_Inout_opt_ PIRP_CONTEXT IrpContext, _Inout_opt_ PIRP Irp, _In_ NTSTATUS Status)
_Requires_lock_held_(c->lock) _When_(return !=0
#define SafeZeroMemory(IC, AT, BYTE_COUNT)
#define CdAllocateIoContext()
#define NT_SUCCESS(StatCode)
enum _TYPE_OF_OPEN TYPE_OF_OPEN
_Inout_ PFILE_OBJECT _In_ TYPE_OF_OPEN PFCB _In_opt_ PCCB Ccb
ClearFlag(Dirent->Flags, DIRENT_FLAG_NOT_PERSISTENT)
_Must_inspect_result_ typedef _In_ PHYSICAL_ADDRESS _In_ LARGE_INTEGER ByteCount
__drv_aliasesMem FORCEINLINE PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(_In_ PIRP Irp)
#define KeInitializeEvent(pEvt, foo, foo2)
#define CdRaiseStatus(IC, S)
_In_ PIO_STACK_LOCATION IrpSp
BOOLEAN CdVerifyFcbOperation(_In_opt_ PIRP_CONTEXT IrpContext, _In_ PFCB Fcb)
#define STATUS_UNEXPECTED_IO_ERROR
#define RtlZeroMemory(Destination, Length)
NTSTATUS NTAPI FsRtlNormalizeNtstatus(IN NTSTATUS NtStatusToNormalize, IN NTSTATUS NormalizedNtStatus)
struct _NAMED_PIPE_CREATE_PARAMETERS * Parameters