dmi_encoder_copy
Description
The dmi_encoder_copy function writes length bytes the model does not
hold at the current position: the ones the source data has there in the
preserve mode, and zeros in the canonical one, or wherever the source data
ends before them.
This is what the bits the specification reserves and the tails of the records longer than the fields they are known to hold are written with.