Exemple #1
0
 protected override void OnClose()
 {
     try
     {
         InnerMessage.Close();
     }
     finally
     {
         _fullBodyBuffer = null;
         _bodyAttributes = null;
         _state          = BodyState.Disposed;
     }
 }
        protected override void OnClose()
        {
            if (_cachedDecryptedBodyContentReader != null)
            {
                try
                {
                    _cachedDecryptedBodyContentReader.Close();
                }
                catch (IOException)
                {
                }
                finally
                {
                    _cachedDecryptedBodyContentReader = null;
                }
            }

            if (_cachedReaderAtSecurityHeader != null)
            {
                try
                {
                    _cachedReaderAtSecurityHeader.Close();
                }
                catch (IOException)
                {
                }
                finally
                {
                    _cachedReaderAtSecurityHeader = null;
                }
            }

            _messageBuffer   = null;
            _decryptedBuffer = null;
            _state           = BodyState.Disposed;
            InnerMessage.Close();
        }