Skip to content

Commit

Permalink
Use sigsetjmp instead of setjmp where appropriate
Browse files Browse the repository at this point in the history
  • Loading branch information
AMDmi3 authored and caclark committed Oct 5, 2023
1 parent 098d336 commit 8bc059f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/image-load-cr3.cc
Expand Up @@ -353,7 +353,7 @@ static gboolean image_loader_cr3_load (gpointer loader, const guchar *buf, gsize
jerr.error = error;


if (setjmp(jerr.setjmp_buffer))
if (sigsetjmp(jerr.setjmp_buffer, 0))
{
/* If we get here, the JPEG code has signaled an error.
* We need to clean up the JPEG object, close the input file, and return.
Expand Down
2 changes: 1 addition & 1 deletion src/image-load-jpeg.cc
Expand Up @@ -313,7 +313,7 @@ static gboolean image_loader_jpeg_load (gpointer loader, const guchar *buf, gsiz
jerr.error = error;


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

0 comments on commit 8bc059f

Please sign in to comment.