Skip to content
Permalink
Browse files
[JENKINS-36871] Found an infinite loop under certain error state disc…
…onnects

- Don't think this affected any real protocols, but better to fix after finding
  • Loading branch information
stephenc committed Aug 2, 2016
1 parent 7062224 commit 90425ad49bac1e6502ace8ad04006c25ed72da34
Showing 1 changed file with 5 additions and 0 deletions.
@@ -328,6 +328,11 @@ private void processRead(@NonNull ByteBuffer readBuffer) throws IOException {
case NOT_HANDSHAKING: // $FALL-THROUGH$
case FINISHED:
appBuffer.clear();
if (!tempBuffer.hasRemaining() && handshakeStatus != SSLEngineResult.HandshakeStatus.NEED_UNWRAP) {
/* we need more data */
done = true;
break;
}
result = sslEngine.unwrap(tempBuffer, appBuffer);
processResult(handshakeStatus, result);

0 comments on commit 90425ad

Please sign in to comment.