Skip to content

Commit 4e61adf

Browse files
committed
Make wording more precise
Resetting the inflater/deflater is never a "must". Only _not_ resetting the inflater is a "must" if the deflater is not being reset.
1 parent 1fd84a9 commit 4e61adf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/org/java_websocket/extensions/permessage_deflate/PerMessageDeflateExtension.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ We can check the getRemaining() method to see whether the data we supplied has b
182182

183183
if (inputFrame.isFin()) {
184184
decompress(TAIL_BYTES, output);
185-
// If context takeover is disabled for the other side, inflater must be reset.
185+
// If context takeover is disabled on the other end, inflater can be reset.
186186
if (resetInflater) {
187187
inflater.reset();
188188
}
@@ -252,7 +252,7 @@ public void encodeFrame(Framedata inputFrame) {
252252
if (endsWithTail(outputBytes)) {
253253
outputLength -= TAIL_BYTES.length;
254254
}
255-
// If context takeover is disabled for this side, deflater must be reset.
255+
// If context takeover is disabled on this end, deflater can be reset.
256256
if (resetDeflater) {
257257
deflater.reset();
258258
}

0 commit comments

Comments
 (0)