コード例 #1
0
ファイル: HMACSHA1.cs プロジェクト: jnm2/corefx
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         HMACCommon hMacCommon = _hMacCommon;
         _hMacCommon = null;
         if (hMacCommon != null)
         {
             hMacCommon.Dispose(disposing);
         }
     }
     base.Dispose(disposing);
 }
コード例 #2
0
        /// <summary>
        /// Release all resources used by the current instance of the
        /// <see cref="IncrementalHash"/> class.
        /// </summary>
        public void Dispose()
        {
            _disposed = true;

            if (_hash != null)
            {
                _hash.Dispose();
                _hash = null;
            }

            if (_hmac != null)
            {
                _hmac.Dispose(true);
                _hmac = null;
            }
        }