Beispiel #1
0
 private void ProcessAlert()
 {
     while (true)
     {
         if (mAlertQueue.Available >= 2)
         {
             byte[] array = mAlertQueue.RemoveData(2, 0);
             byte   b     = array[0];
             byte   b2    = array[1];
             Peer.NotifyAlertReceived(b, b2);
             if (b == 2)
             {
                 break;
             }
             if (b2 == 0)
             {
                 HandleClose(user_canceled: false);
             }
             HandleWarningMessage(b2);
             continue;
         }
         return;
     }
     InvalidateSession();
     mFailedWithError = true;
     mClosed          = true;
     mRecordStream.SafeClose();
     throw new IOException(TLS_ERROR_MESSAGE);
 }