Support partial body length headers

This adds support for partial body length headers and includes a test case.