Skip to content

Commit

Permalink
Change back default allocator to pooled.
Browse files Browse the repository at this point in the history
Motivation:

While porting some changes from 4.0 to 4.1 and master branch I changed the default allocator from pooled to unpooled by mistake. This should be reverted. The guilty commit is 4a3ef90.

Thanks to @blucas for spotting this.

Modifications:

Revert changes related to allocator.

Result:

Use the correct default allocator again.
  • Loading branch information
Norman Maurer committed Aug 13, 2014
1 parent 8cfc64f commit 4a379f0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion buffer/src/main/java/io/netty/buffer/ByteBufUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ public final class ByteBufUtil {
HEXDUMP_TABLE[(i << 1) + 1] = DIGITS[i & 0x0F];
}

String allocType = SystemPropertyUtil.get("io.netty.allocator.type", "unpooled").toLowerCase(Locale.US).trim();
String allocType = SystemPropertyUtil.get(
"io.netty.allocator.type", PlatformDependent.isAndroid() ? "unpooled" : "pooled");
allocType = allocType.toLowerCase(Locale.US).trim();

ByteBufAllocator alloc;
if ("unpooled".equals(allocType)) {
Expand Down

0 comments on commit 4a379f0

Please sign in to comment.