about summary refs log tree commit diff
path: root/sysdeps/libm-ieee754/s_nextafter.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/libm-ieee754/s_nextafter.c')
-rw-r--r--sysdeps/libm-ieee754/s_nextafter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/libm-ieee754/s_nextafter.c b/sysdeps/libm-ieee754/s_nextafter.c
index ee973bcee8..b98a161cf2 100644
--- a/sysdeps/libm-ieee754/s_nextafter.c
+++ b/sysdeps/libm-ieee754/s_nextafter.c
@@ -42,7 +42,7 @@ static char rcsid[] = "$NetBSD: s_nextafter.c,v 1.8 1995/05/10 20:47:58 jtc Exp
 	if(((ix>=0x7ff00000)&&((ix-0x7ff00000)|lx)!=0) ||   /* x is nan */
 	   ((iy>=0x7ff00000)&&((iy-0x7ff00000)|ly)!=0))     /* y is nan */
 	   return x+y;
-	if(x==y) return x;		/* x=y, return x */
+	if(x==y) return y;		/* x=y, return y */
 	if((ix|lx)==0) {			/* x == 0 */
 	    INSERT_WORDS(x,hy&0x80000000,1);	/* return +-minsubnormal */
 	    y = x*x;