Use new byte buffer utils.
Scratch that, we need to be able to cancel.
Preserve memory and don't reference out of scope variables.
Update example files.