diff options
author | Ray Johnston <ray.johnston@artifex.com> | 2009-10-01 14:27:36 +0000 |
---|---|---|
committer | Ray Johnston <ray.johnston@artifex.com> | 2009-10-01 14:27:36 +0000 |
commit | 5caea24716bbbeb97a9582c42cae69ccde813a3d (patch) | |
tree | f4a6c03322b82a7326eb8469e844cf2b8739d829 /xps/ghostxps.h | |
parent | d44947d53d93a1b9d07a74000e455856a1242c38 (diff) |
Fix for segfault when peekstring requests more data than remains in a
%rom% file. Bug 690697.
DETAILS:
The EOFC was not being set correctly, so a subsequent operation would have
cursor.r values that were invalid. Refer to the invariant in the documentation
in stream.h for the stream_s structure:
s->position represents the stream position as of the beginning of the
buffer, so the current position is s->position + (s->srptr + 1 - s->cbuf).
Note that we must not return EOFC when reading exactly the remaining number of
bytes in a file since this will result in the stream being closed. PCL relies
on the stream remaining open after reading the number of bytes in the file.
EXPECTED DIFFERENCES:
None.
git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@10106 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'xps/ghostxps.h')
0 files changed, 0 insertions, 0 deletions