3 writes to _handle
System.Core (3)
System\IO\LogStream.cs (3)
128
_handle
= UnsafeNativeMethods.SafeCreateFile(filePath, fAccess, share, secAttrs, mode, flagsAndAttributes, UnsafeNativeMethods.NULL);
349
_handle
= null;
407
_handle
= handle;
17 references to _handle
System.Core (17)
System\IO\LogStream.cs (17)
131
if (
_handle
.IsInvalid) {
160
Debug.Assert(UnsafeNativeMethods.GetFileType(
_handle
) == UnsafeNativeMethods.FILE_TYPE_DISK, "did someone accidentally removed the device type check from SafeCreateFile P/Invoke wrapper?");
242
EnforceRetentionPolicy(
_handle
, streamPos);
249
if (
_handle
.IsClosed) __Error.FileNotOpen();
277
r = UnsafeNativeMethods.WriteFile(
_handle
, p + offset, count, out numBytesWritten, overlapped);
291
_handle
.SetHandleAsInvalid();
306
Debug.Assert(!
_handle
.IsClosed, "!_handle.IsClosed");
311
ret = UnsafeNativeMethods.SetFilePointer(
_handle
, offset, origin, out hr);
317
_handle
.SetHandleAsInvalid();
335
if (
_handle
== null ||
_handle
.IsClosed) {
346
if (
_handle
!= null && !
_handle
.IsClosed)
347
_handle
.Dispose();
360
if (
_handle
!= null) {
372
if ((lastPos >= _maxFileSize) && (handle ==
_handle
)){
374
if ((handle !=
_handle
) || (lastPos < _maxFileSize))