Don't corrupt UTF-8 in Node.JS streams

When sending Buffers to the stream interface, check whether
the chunk ends with an incomplete multi-byte sequence.
If it does, then strip it off and add to the beginning of the
next chunk.
If the stream ends with an incomplete sequence, pass it through
unchanged.

Using the Buffer global here should be OK, as the stream interface
should only be being used in a Node.JS environment.
Tests for UTF-8 multi-byte handling