about summary refs log tree commit diff
path: root/sysdeps/libm-ieee754/s_exp2.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/libm-ieee754/s_exp2.c')
-rw-r--r--sysdeps/libm-ieee754/s_exp2.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sysdeps/libm-ieee754/s_exp2.c b/sysdeps/libm-ieee754/s_exp2.c
index e10fae5492..fc3fd2507b 100644
--- a/sysdeps/libm-ieee754/s_exp2.c
+++ b/sysdeps/libm-ieee754/s_exp2.c
@@ -1,5 +1,5 @@
 /* Double-precision floating point 2^x.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1998 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Geoffrey Keating <geoffk@ozemail.com.au>
 
@@ -54,7 +54,10 @@ __ieee754_exp2 (double x)
       fenv_t oldenv;
 
       feholdexcept (&oldenv);
+#ifdef FE_TONEAREST
+      /* If we don't have this, it's too bad.  */
       fesetround (FE_TONEAREST);
+#endif
 
       /* 1. Argument reduction.
 	 Choose integers ex, -256 <= t < 256, and some real