Opened 4 years ago

Closed 4 years ago

#7274 closed bug (duplicate)

hp2ps sometimes creates invalid postscript files

Reported by: edsko Owned by:
Priority: normal Milestone:
Component: Compiler Version: 7.6.1
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


The attached .hp file is one example; running the resulting ps file through ps2pdf gives

Error: /syntaxerror in -file- Operand stack:

Execution stack:

%interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1894 1 3 %oparray_pop 1893 1 3 %oparray_pop 1877 1 3 %oparray_pop 1771 1 3 %oparray_pop --nostringval-- %errorexec_pop .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push

Dictionary stack:

--dict:1157/1684(ro)(G)-- --dict:0/20(G)-- --dict:79/200(L)--

Current allocation mode is local Last OS error: 2 Current file position is 12516 GPL Ghostscript 9.05: Unrecoverable error, exit code 1

Attachments (1)

distributed-process-simplelocalnet-masterslave.hp (34.1 KB) - added by edsko 4 years ago.
.hp file that exposes the bug in hp2ps

Download all attachments as: .zip

Change History (4)

Changed 4 years ago by edsko

.hp file that exposes the bug in hp2ps

comment:1 Changed 4 years ago by edsko

(Incidentally, a workaround is using hp2pretty.)

comment:2 Changed 4 years ago by fryguybob

It is failing to correctly escape the string on line 318 of the Postscript file: ((227)master.\/master/main.\) show

comment:3 Changed 4 years ago by fryguybob

Resolution: duplicate
Status: newclosed

This is a duplicate of #5800. I didn't think it was at first, but then discovered that there are two places that strings are escaped, one only deals with backslash and the other only deals with parentheses. We might consider consolidating these.

Note: See TracTickets for help on using tickets.