Пример #1
0
        protected override void Dispose(bool disposing)
        {
            base.Dispose(disposing);

            if (disposing)
            {
                if (_handle != null && !_handle.IsInvalid)
                {
                    _handle.Close();
                    _handle = null;
                }

                if (_owner != null)
                {
                    _owner.RemoveOwnedFile(this);
                    _owner = null;
                }
            }
        }
Пример #2
0
 internal MpqFileStream(MpqFileSafeHandle handle, FileAccess accessType, MpqArchive owner)
 {
     _handle     = handle;
     _accessType = accessType;
     _owner      = owner;
 }
Пример #3
0
 internal MpqFileStream(MpqFileSafeHandle handle, FileAccess accessType, MpqArchive owner)
 {
     _handle = handle;
     _accessType = accessType;
     _owner = owner;
 }
Пример #4
0
        protected override void Dispose(bool disposing)
        {
            base.Dispose(disposing);

            if (disposing)
            {
                if (_handle != null && !_handle.IsInvalid)
                {
                    _handle.Close();
                    _handle = null;
                }

                if (_owner != null)
                {
                    _owner.RemoveOwnedFile(this);
                    _owner = null;
                }
            }
        }