public void OnClearStream() { Logger.Info($"{streamType}"); // Remove reference count held by Packet Stream. // Player may still have packets and process them. Don't force remove // drmSession?.Release(); drmSession = null; config = null; }
// Use override to assure base class object references // of type EncryptedPacket will call this Dispose, not the base class // protected override void Dispose(bool disposing) { if (IsDisposed) { return; } if (disposing) { DrmSession?.Release(); } IsDisposed = true; }
// Use override to assure base class object references // of type EncryptedPacket will call this Dispose, not the base class // protected override void Dispose(bool disposing) { if (!IsDisposed) { if (disposing) { DrmSession?.Release(); } IsDisposed = true; } base.Dispose(disposing); }