add chunked decoding and test for it
Merge pull request #1 from tgulacsi/chunked

add chunked decoding and test for it