jifmux: Avoid copying image payload
Wrap the new header in a memory and prepend to the buffer instead of copying the whole image to a new buffer.
Wrap the new header in a memory and prepend to the buffer instead of copying the whole image to a new buffer.