(feupdateenv): Use only sw[0] and call feraiseexcept.

This commit is contained in:
Ulrich Drepper 2004-04-17 22:51:43 +00:00
parent 57f4291c9d
commit 87ffc6ec79
1 changed files with 2 additions and 3 deletions

View File

@ -27,11 +27,10 @@ feupdateenv (const fenv_t *envp)
/* Get the current exception status. */
__asm__ ("fstd %%fr0,0(%1)" : "=m" (*sw) : "r" (sw));
sw[0] &= FE_ALL_EXCEPT;
envp->__status_word = envp->__status_word | sw[0];
/* Install new environment. */
fesetenv (envp);
/* Raise the saved exceptions */
feraiseexcept(sw[0] & FE_ALL_EXCEPT);
/* Success. */
return 0;