summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-09-21 14:18:08 +0100
committerSam James <sam@gentoo.org>2022-10-02 04:31:25 +0100
commita529111f77ff46f4836fe7312e70953bc16587cf (patch)
tree9dc3924cb1a6ef3ef853b7bb45f735365e0b4e6d /devices/vector/gdevpdfj.c
parentImport Ghostscript 9.56.1 (diff)
downloadghostscript-gpl-patches-ghostscript-10.0.tar.gz
ghostscript-gpl-patches-ghostscript-10.0.tar.bz2
ghostscript-gpl-patches-ghostscript-10.0.zip
Import Ghostscript 10.0ghostscript-10.0ghostscript-10
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'devices/vector/gdevpdfj.c')
-rw-r--r--devices/vector/gdevpdfj.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/devices/vector/gdevpdfj.c b/devices/vector/gdevpdfj.c
index 02692510..5888ac70 100644
--- a/devices/vector/gdevpdfj.c
+++ b/devices/vector/gdevpdfj.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001-2021 Artifex Software, Inc.
+/* Copyright (C) 2001-2022 Artifex Software, Inc.
All Rights Reserved.
This software is provided AS-IS with no warranty, either express or
@@ -348,8 +348,10 @@ pdf_begin_write_image(gx_device_pdf * pdev, pdf_image_writer * piw,
}
pdev->strm = pdev->streams.strm;
pdev->strm = cos_write_stream_alloc(data, pdev, "pdf_begin_write_image");
- if (pdev->strm == 0)
+ if (pdev->strm == 0) {
+ pdev->strm = save_strm;
return_error(gs_error_VMerror);
+ }
if (!mask)
piw->data = data;
piw->height = h;