Data are stored on a random-access storage medium. A user set of data is
received. The user set of data is mapped to multiple frames. For each
frame, error-correction bytes are generated over the data mapped to that
frame. In addition, the data mapped to that frame are written to a number
of data blocks of that frame and the error-correction bytes generated for
that frame are written to a number of error-correction blocks of that
frame. At least one of the number of error-correction blocks and the
number of data blocks differs among at least some of the frames.