Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3807262
tryme2.diff
All Users
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
thierry1970
File Metadata
Details
File Info
Storage
Attached
Author
raster
Created
Dec 2 2019, 6:07 AM
Size
2 KB
Mime Type
text/x-diff
Engine
local-disk
Format
Raw Data
Handle
29/8a/1e00e7cc53608898cc53f59e0b06
Attached To
F3807224: tryme.diff
T8497: SIGABRT on JPEG with TIFF DATA loaded with an exif rotation.
tryme2.diff
View Options
diff --git a/src/lib/emile/emile_image.c b/src/lib/emile/emile_image.c
index 4f6e11905e..21317cbe15 100644
--- a/src/lib/emile/emile_image.c
+++ b/src/lib/emile/emile_image.c
@@ -1750,8 +1750,8 @@ _emile_jpeg_data(Emile_Image *image,
uint8_t *ptr, *line[16], *data;
volatile uint32_t *ptr2 = NULL;
uint32_t *ptr_rotate = NULL;
- uint16_t *ptrag = NULL, *ptrag_rotate = NULL;
- uint8_t *ptrg = NULL, *ptrg_rotate = NULL;
+ uint16_t *ptrag = NULL, *ptrag2 = NULL, *ptrag_rotate = NULL;
+ uint8_t *ptrg = NULL, *ptrg2 = NULL, *ptrg_rotate = NULL;
unsigned int y, l, i, scans;
volatile int region = 0;
/* rotation setting */
@@ -2113,6 +2113,8 @@ _emile_jpeg_data(Emile_Image *image,
/* We finally handle RGB with 1 component */
else if (cinfo.output_components == 1)
{
+ ptrg2 = ptrg;
+ ptrag2 = ptrag;
for (i = 0; (int)i < cinfo.rec_outbuf_height; i++)
line[i] = data + (i * w);
for (l = 0; l < h; l += cinfo.rec_outbuf_height)
@@ -2132,10 +2134,10 @@ _emile_jpeg_data(Emile_Image *image,
switch (prop->cspace)
{
case EMILE_COLORSPACE_GRY8:
- _jpeg_gry8_convert_copy(&ptrg, &ptr, w);
+ _jpeg_gry8_convert_copy(&ptrg2, &ptr, w);
break;
case EMILE_COLORSPACE_AGRY88:
- _jpeg_agry88_convert_copy(&ptrag, &ptr, w);
+ _jpeg_agry88_convert_copy(&ptrag2, &ptr, w);
break;
default:
_jpeg_argb8888_convert_copy(&ptr2, &ptr, w);
@@ -2168,10 +2170,10 @@ _emile_jpeg_data(Emile_Image *image,
switch (prop->cspace)
{
case EMILE_COLORSPACE_GRY8:
- _jpeg_gry8_convert_copy(&ptrg, &ptr, opts_region.w);
+ _jpeg_gry8_convert_copy(&ptrg2, &ptr, opts_region.w);
break;
case EMILE_COLORSPACE_AGRY88:
- _jpeg_agry88_convert_copy(&ptrag, &ptr, opts_region.w);
+ _jpeg_agry88_convert_copy(&ptrag2, &ptr, opts_region.w);
break;
default:
_jpeg_argb8888_convert_copy(&ptr2, &ptr, opts_region.w);
thierry1970
added a subscriber:
thierry1970
.
Dec 2 2019, 7:19 AM
Comment Actions
It's fixed, nice work!
Thank you :)
Log In to Comment