Skip to content

Commit

Permalink
Remove setjmp.h.
Browse files Browse the repository at this point in the history
  • Loading branch information
ncruces committed Oct 23, 2023
1 parent fc8e155 commit 2432c77
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion dcraw.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
#include <float.h>
#include <limits.h>
#include <math.h>
#include <setjmp.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
Expand Down Expand Up @@ -140,6 +139,14 @@ const float d65_white[3] = { 0.950456, 1, 1.088754 };
int histogram[4][0x2000];
void (*write_thumb)(), (*write_fun)();
void (*load_raw)(), (*thumb_load_raw)();

typedef struct{} jmp_buf;
static int setjmp(jmp_buf env) { return 0; }
static __attribute__((noreturn)) void longjmp(jmp_buf env, int val) {
if (fileno(ifp) > 2) fclose(ifp);
if (fileno(ofp) > 2) fclose(ofp);
exit(1);
}
jmp_buf failure;

struct decode {
Expand Down

0 comments on commit 2432c77

Please sign in to comment.