[#1714] Make sure ByteArrayDecoder also works correctly with pooled buffers