redjack/libcork — pull request #87 by dcreager (2014-09-12 19:25:01+00:00)
Title: Don't clear buffer when consuming stream

The `cork_buffer_to_stream_consumer` function claims that the resulting stream consumer will append to the buffer, but previously it would clear the buffer when it received the first chunk of data. That means that we could't consume data into an existing buffer while keeping any previous contents. This patch updates the consumer implementation to actually perform an append.