Skip to content

Commit

Permalink
Ensure PooledByteBuf.init() is not called with null memory
Browse files Browse the repository at this point in the history
  • Loading branch information
trustin committed Dec 17, 2012
1 parent ba3c795 commit 33134b1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions buffer/src/main/java/io/netty/buffer/PooledByteBuf.java
Expand Up @@ -40,6 +40,8 @@ protected PooledByteBuf(int maxCapacity) {

void init(PoolChunk<T> chunk, long handle, T memory, int offset, int length) {
assert handle >= 0;
assert memory != null;

this.chunk = chunk;
this.handle = handle;
this.memory = memory;
Expand Down

0 comments on commit 33134b1

Please sign in to comment.