fixing bug where `start` was getting overriden if buffer-remaining was > 0, leading to data overlap issues when pulling data out of output buffer.