Skip to content

Commit 8bc059f

Browse files
AMDmi3caclark
authored andcommitted
Use sigsetjmp instead of setjmp where appropriate
1 parent 098d336 commit 8bc059f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/image-load-cr3.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ static gboolean image_loader_cr3_load (gpointer loader, const guchar *buf, gsize
353353
jerr.error = error;
354354

355355

356-
if (setjmp(jerr.setjmp_buffer))
356+
if (sigsetjmp(jerr.setjmp_buffer, 0))
357357
{
358358
/* If we get here, the JPEG code has signaled an error.
359359
* We need to clean up the JPEG object, close the input file, and return.

src/image-load-jpeg.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ static gboolean image_loader_jpeg_load (gpointer loader, const guchar *buf, gsiz
313313
jerr.error = error;
314314

315315

316-
if (setjmp(jerr.setjmp_buffer))
316+
if (sigsetjmp(jerr.setjmp_buffer, 0))
317317
{
318318
/* If we get here, the JPEG code has signaled an error.
319319
* We need to clean up the JPEG object, close the input file, and return.

0 commit comments

Comments
 (0)