decoder: use writeAll wrapper to write iframe data

Large iframes are not guaranteed to be written with
a single write call.
Deal with incomplete writes.