Author: tkreuzer Date: Thu May 14 21:52:23 2015 New Revision: 67728
URL: http://svn.reactos.org/svn/reactos?rev=67728&view=rev Log: [CRT] Don't use _control87 on ARM builds
Modified: trunk/reactos/lib/sdk/crt/string/scanf.h trunk/reactos/lib/sdk/crt/string/winesup.c
Modified: trunk/reactos/lib/sdk/crt/string/scanf.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/string/scanf.h?... ============================================================================== --- trunk/reactos/lib/sdk/crt/string/scanf.h [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/string/scanf.h [iso-8859-1] Thu May 14 21:52:23 2015 @@ -408,10 +408,13 @@ _internal_handle_float(negative, exp, suppress, d, l_prefix || L_prefix, &ap); st = 1; #else +#ifdef _M_ARM + DbgBreakPoint(); +#else fpcontrol = _control87(0, 0); _control87(MSVCRT__EM_DENORMAL|MSVCRT__EM_INVALID|MSVCRT__EM_ZERODIVIDE |MSVCRT__EM_OVERFLOW|MSVCRT__EM_UNDERFLOW|MSVCRT__EM_INEXACT, 0xffffffff); - +#endif negexp = (exp < 0); if(negexp) exp = -exp; @@ -423,9 +426,11 @@ expcnt = expcnt*expcnt; } cur = (negexp ? d/cur : d*cur); - +#ifdef _M_ARM + DbgBreakPoint(); +#else _control87(fpcontrol, 0xffffffff); - +#endif st = 1; if (!suppress) { if (L_prefix) _SET_NUMBER_(double);
Modified: trunk/reactos/lib/sdk/crt/string/winesup.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/string/winesup.... ============================================================================== --- trunk/reactos/lib/sdk/crt/string/winesup.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/string/winesup.c [iso-8859-1] Thu May 14 21:52:23 2015 @@ -75,11 +75,14 @@ long double cur = 1, expcnt = 10; unsigned fpcontrol; BOOL negexp; - +#ifdef _M_ARM + DbgBreakPoint(); + fpcontrol = _controlfp(0, 0); +#else fpcontrol = _control87(0, 0); _control87(_EM_DENORMAL|_EM_INVALID|_EM_ZERODIVIDE |_EM_OVERFLOW|_EM_UNDERFLOW|_EM_INEXACT, 0xffffffff); - +#endif negexp = (exp < 0); if(negexp) exp = -exp; @@ -92,7 +95,12 @@ } cur = (negexp ? d/cur : d*cur);
+#ifdef _M_ARM + DbgBreakPoint(); + _controlfp(fpcontrol, 0xffffffff); +#else _control87(fpcontrol, 0xffffffff); +#endif
if (!suppress) { if (l_or_L_prefix) _SET_NUMBER_(double);