]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Patch #103012: Update fpectlmodule for current glibc;
authorAndrew M. Kuchling <amk@amk.ca>
Thu, 4 Jan 2001 01:01:12 +0000 (01:01 +0000)
committerAndrew M. Kuchling <amk@amk.ca>
Thu, 4 Jan 2001 01:01:12 +0000 (01:01 +0000)
    The _setfpucw() function/macro doesn't seem to exist any more;
    instead there's an _FPU_SETCW macro.

Modules/fpectlmodule.c

index 803448960a485b458ba4064215aef88eeb768695..ff3ea76dd53b6e26a34ee7bc7c8fc57c200a8a64 100644 (file)
@@ -195,7 +195,14 @@ static void fpe_reset(Sigfunc *handler)
 #else
 #include <i386/fpu_control.h>
 #endif
+#ifdef _FPU_SETCW
+    {
+        fpu_control_t cw = 0x1372;
+        _FPU_SETCW(cw);
+    }
+#else
     __setfpucw(0x1372);
+#endif
     PyOS_setsig(SIGFPE, handler);
 
 /*-- NeXT -----------------------------------------------------------------*/