1085f8416SMike Barcroft /*- 2085f8416SMike Barcroft * $NetBSD: setjmp.h,v 1.3 1998/09/16 23:51:27 thorpej Exp $ 3085f8416SMike Barcroft * $FreeBSD$ 4085f8416SMike Barcroft */ 527499504SDavid E. O'Brien 699bc8c72SBenno Rice #ifndef _MACHINE_SETJMP_H_ 799bc8c72SBenno Rice #define _MACHINE_SETJMP_H_ 899bc8c72SBenno Rice 9e61d3b10SMike Barcroft #include <sys/cdefs.h> 10e61d3b10SMike Barcroft 1199bc8c72SBenno Rice #define _JBLEN 100 1227499504SDavid E. O'Brien 1327499504SDavid E. O'Brien /* 1427499504SDavid E. O'Brien * jmp_buf and sigjmp_buf are encapsulated in different structs to force 1527499504SDavid E. O'Brien * compile-time diagnostics for mismatches. The structs are the same 1627499504SDavid E. O'Brien * internally to avoid some run-time errors for mismatches. 1727499504SDavid E. O'Brien */ 18e61d3b10SMike Barcroft #if __BSD_VISIBLE || __POSIX_VISIBLE || __XSI_VISIBLE 1999bc8c72SBenno Rice typedef struct _sigjmp_buf { long _sjb[_JBLEN + 1]; } sigjmp_buf[1]; 2099bc8c72SBenno Rice #endif 2127499504SDavid E. O'Brien 2299bc8c72SBenno Rice typedef struct _jmp_buf { long _jb[_JBLEN + 1]; } jmp_buf[1]; 2399bc8c72SBenno Rice 24085f8416SMike Barcroft #endif /* !_MACHINE_SETJMP_H_ */ 25