[tex-live] dviselect error: invalid empty DVI file created
jschrod at acm.org
Wed May 7 10:22:04 CEST 2008
To whom it may concern... :-)
I'm using dviselect and stumbled over an error in it, and a subtle
problem in dvitype.
The error: If one uses a page specifier that does not exist in a
file, an invalid DVI file is created.
Example: Take a DVI file from an arbitrary LaTeX file and call
dviselect '*.1234' infile.dvi outfile.dvi
outfile.dvi will by 84 bytes in size and will be invalid:
dvitype will not tell you, you need to use dv2dt to see that the
pointer in the DVI command post is wrong. In my tests, it is an
arbitrary high number that has no relation to the new or the
It's an interesting question what number should be there. The DVI
specs say that p in a post should be the pointer to the last
bop, but we don't have a bop in that file. So maybe it would be
better to use a pointer to the pre command instead.
In any case, it would be sensible to output a respective error
message and exit with an exit code != 0.
Joachim Schrod Email: jschrod at acm.org
More information about the tex-live