|
@@ -56,6 +56,15 @@
|
|
# define EWOULDBLOCK WSAEWOULDBLOCK
|
|
# define EWOULDBLOCK WSAEWOULDBLOCK
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
+#if defined(_WIN64)
|
|
|
|
+/* On w64, setjmp is implemented by _setjmp which needs a second parameter.
|
|
|
|
+ * If this parameter is NULL, longjump does no stack unwinding.
|
|
|
|
+ * That is what we need for QEMU. Passing the value of register rsp (default)
|
|
|
|
+ * lets longjmp try a stack unwinding which will crash with generated code. */
|
|
|
|
+# undef setjmp
|
|
|
|
+# define setjmp(env) _setjmp(env, NULL)
|
|
|
|
+#endif
|
|
|
|
+
|
|
/* Declaration of ffs() is missing in MinGW's strings.h. */
|
|
/* Declaration of ffs() is missing in MinGW's strings.h. */
|
|
int ffs(int i);
|
|
int ffs(int i);
|
|
|
|
|