summaryrefslogtreecommitdiff
path: root/gs/src/gdevwts.c
diff options
context:
space:
mode:
authorRay Johnston <ray.johnston@artifex.com>2007-11-01 20:49:28 +0000
committerRay Johnston <ray.johnston@artifex.com>2007-11-01 20:49:28 +0000
commitc472250dac22f522f3d78cfc0d5b5a15d41cd7a0 (patch)
tree3df347a38054b531abdc135c6a554b105d257926 /gs/src/gdevwts.c
parent1ed1a30dc9f2f3881221912b0501559b53459fcf (diff)
Make sure that errors are propogated to caller in the WTS device (such
as VMerror). Bug 689511 for customer 951. DETAILS: This doesn't really fix the underlying problem seen by the (embedded) customer where the clist rendering uses a large amount of RAM. EXPECTED DIFFERENCES: None. git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@8344 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'gs/src/gdevwts.c')
-rw-r--r--gs/src/gdevwts.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/gs/src/gdevwts.c b/gs/src/gdevwts.c
index 68ee4036e..8298258a2 100644
--- a/gs/src/gdevwts.c
+++ b/gs/src/gdevwts.c
@@ -407,7 +407,9 @@ wtscmyk_print_page(gx_device_printer *pdev, FILE *prn_stream)
/* For each raster line */
for (y = 0; y < pdev->height; y++) {
- gdev_prn_get_bits(pdev, y, cmyk_line, &data);
+ code = gdev_prn_get_bits(pdev, y, cmyk_line, &data);
+ if (code < 0)
+ break; /* return the code below after cleanup */
wts_halftone_line_8(wdev->wcooked, y, pdev->width, n_planes,
wdev->band_offset_x, wdev->band_offset_y, dst, data);
for (i = 0; i < n_planes; i++)
@@ -1102,7 +1104,9 @@ wtsimdi_print_page(gx_device_printer *pdev, FILE *prn_stream)
* The get_bit routines for our device returns a halftoned copy of
* the output data. Print this data to the output file.
*/
- gdev_prn_get_bits(pdev, y, halftoned_buffer, &halftoned_data);
+ code = gdev_prn_get_bits(pdev, y, halftoned_buffer, &halftoned_data);
+ if (code < 0)
+ break; /* return code below after cleanup */
if (!output_is_nul)
write_pkmraw_row(width, halftoned_data, prn_stream);
}