Encoding is irrelevant when writing bytes to a buffer