Fix buffer leaks in XmlFrameDecoderTest

This commit is contained in:
Trustin Lee 2013-12-16 15:36:49 +09:00
parent 502ccabab3
commit 457cd2f6fa

View File

@ -155,6 +155,7 @@ public class XmlFrameDecoderTest {
break; break;
} }
actual.add(buf.toString(CharsetUtil.UTF_8)); actual.add(buf.toString(CharsetUtil.UTF_8));
buf.release();
} }
if (cause != null) { if (cause != null) {
@ -175,5 +176,4 @@ public class XmlFrameDecoderTest {
byte[] buf = Files.readAllBytes(Paths.get(url.toURI())); byte[] buf = Files.readAllBytes(Paths.get(url.toURI()));
return StandardCharsets.UTF_8.decode(ByteBuffer.wrap(buf)).toString(); return StandardCharsets.UTF_8.decode(ByteBuffer.wrap(buf)).toString();
} }
} }