mirror of
https://github.com/reactos/reactos.git
synced 2025-07-29 09:12:20 +00:00
[MSVCRT]
- Properly implement and export _fpcontrol_s svn path=/trunk/; revision=57823
This commit is contained in:
parent
a7321eec6d
commit
f17fe2fe20
2 changed files with 9 additions and 9 deletions
|
@ -302,7 +302,7 @@
|
||||||
@ extern _commode
|
@ extern _commode
|
||||||
@ cdecl _control87(long long)
|
@ cdecl _control87(long long)
|
||||||
@ cdecl _controlfp(long long)
|
@ cdecl _controlfp(long long)
|
||||||
# @ cdecl _controlfp_s(ptr long long)
|
@ cdecl _controlfp_s(ptr long long)
|
||||||
@ cdecl _copysign( double double )
|
@ cdecl _copysign( double double )
|
||||||
@ varargs _cprintf(str)
|
@ varargs _cprintf(str)
|
||||||
# stub _cprintf_l
|
# stub _cprintf_l
|
||||||
|
|
|
@ -120,15 +120,15 @@ unsigned int CDECL _control87(unsigned int newval, unsigned int mask)
|
||||||
int CDECL _controlfp_s(unsigned int *cur, unsigned int newval, unsigned int mask)
|
int CDECL _controlfp_s(unsigned int *cur, unsigned int newval, unsigned int mask)
|
||||||
{
|
{
|
||||||
#ifdef __i386__
|
#ifdef __i386__
|
||||||
unsigned int flags;
|
unsigned int val;
|
||||||
|
|
||||||
FIXME("(%p %u %u) semi-stub\n", cur, newval, mask);
|
|
||||||
|
|
||||||
flags = _control87( newval, mask & ~_EM_DENORMAL );
|
|
||||||
|
|
||||||
if(cur)
|
|
||||||
*cur = flags;
|
|
||||||
|
|
||||||
|
if (!MSVCRT_CHECK_PMT( !(newval & mask & ~(_MCW_EM | _MCW_IC | _MCW_RC | _MCW_PC | _MCW_DN))))
|
||||||
|
{
|
||||||
|
if (cur) *cur = _controlfp( 0, 0 ); /* retrieve it anyway */
|
||||||
|
return MSVCRT_EINVAL;
|
||||||
|
}
|
||||||
|
val = _controlfp( newval, mask );
|
||||||
|
if (cur) *cur = val;
|
||||||
return 0;
|
return 0;
|
||||||
#else
|
#else
|
||||||
FIXME(":Not Implemented!\n");
|
FIXME(":Not Implemented!\n");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue