Data written to the z/OS® Language Environment® message file is always appended to the
end of the file.
When the data written is longer than 255 bytes, it is written
to the z/OS Language
Environment message file 255 bytes at a time, with the last write
possibly less than 255 bytes. No truncation will occur.
When the output data is shorter than the actual LRECL of the z/OS Language
Environment message
file, it is padded with blank characters by the z/OS Language
Environment system write
interface.
When the output data is longer than the actual LRECL of the z/OS Language
Environment message
file, it is split into multiple records by the z/OS Language
Environment system write
interface. The z/OS Language
Environment system write interface splits the output data
at the last blank before the LRECL-th byte, and begins writing the
next record with the first non-blank character. Note that if there
are no blanks in the first LRECL bytes (DBCS for instance), the z/OS Language
Environment system
write interface splits the output data at the LRECL-th byte. It
also closes off any DBCS string on the first record with a X'0F' character,
and begins the DBCS string on the next record with a X'0E' character.
The hex characters X'0E' and X'0F' have special
meaning to the z/OS Language
Environment system write interface. The z/OS Language
Environment system write
interface removes adjacent pairs of these characters (normalization).
You can set up a SIGIOERR handler to catch system write
errors. See Debugging I/O programs for more information.