Skip to content

Commit 3d328e9

Browse files
committed
Add assertion
1 parent 4230539 commit 3d328e9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

msgpack-core/src/main/java/org/msgpack/core/MessageUnpacker.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ public long getTotalReadBytes()
171171

172172
/**
173173
* Get the next buffer without changing the position
174+
*
174175
* @return
175176
* @throws IOException
176177
*/
@@ -181,6 +182,7 @@ private MessageBuffer getNextBuffer()
181182
if (next == null) {
182183
throw new MessageInsufficientBufferException();
183184
}
185+
assert (buffer != null);
184186
totalReadBytes += buffer.size();
185187
return next;
186188
}
@@ -194,6 +196,7 @@ private void nextBuffer()
194196

195197
/**
196198
* Returns a short size buffer (upto 8 bytes) to read a number value
199+
*
197200
* @param readLength
198201
* @return
199202
* @throws IOException

0 commit comments

Comments
 (0)