And, this one does the same thing for decode.
Attaching a better patch which uses a larger default buffer and removes the makefile...
Non-Stream Encoding