diff options
author | Henry Stiles <henry.stiles@artifex.com> | 1999-05-24 20:03:13 +0000 |
---|---|---|
committer | Henry Stiles <henry.stiles@artifex.com> | 1999-05-24 20:03:13 +0000 |
commit | 5e99d00db40250c4aec92e2e7ecaf51f629540ae (patch) | |
tree | c59a16131c363a845609bb0786adc205d3f6fddc /gs/src/seexec.c | |
parent | 7ddfba499458819bf0dbf297b084f8b5b51b8690 (diff) |
initial gs5.84 checkin with pcl and xl compiling.
git-svn-id: http://svn.ghostscript.com/ghostpcl/trunk/ghostpcl@857 06663e23-700e-0410-b217-a244a6096597
Diffstat (limited to 'gs/src/seexec.c')
-rw-r--r-- | gs/src/seexec.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/gs/src/seexec.c b/gs/src/seexec.c index 6281383c0..5ef6f5adb 100644 --- a/gs/src/seexec.c +++ b/gs/src/seexec.c @@ -146,12 +146,20 @@ s_exD_process(stream_state * st, stream_cursor_read * pr, } else { /* * We only ignore leading whitespace, in an attempt to - * keep from reading beyond the end of the encrypted data. + * keep from reading beyond the end of the encrypted data; + * but some badly coded files require us to ignore % also. */ - status = s_hex_process(pr, pw, &ss->odd, +hp: status = s_hex_process(pr, pw, &ss->odd, hex_ignore_leading_whitespace); - p = q; count = pw->ptr - q; + if (status < 0 && ss->odd < 0) { + if (count) { + --p; + status = 0; /* reprocess error next time */ + } else if (*p == '%') + goto hp; /* ignore % */ + } + p = q; } if (skip >= count && skip != 0) { gs_type1_decrypt(q + 1, p + 1, count, |