emicklei/go-restful — pull request #151 by clsung (2014-09-24 15:25:26+00:00)
Title: extract method and use bytes.NewReader() to interface byte[]

ReadEntity() is modified without touching cachingReadEntity(). So the problem exists if we didn't call SetCacheReadEntity(false). Therefore the behavior is inconsistent.

This pr extracts the decoding process, also attached with test case.