vx32

Local 9vx git repository for patches.
git clone git://r-36.net/vx32
Log | Files | Refs

commit c4c41028787128a63eaf8bfe9330fd7baaacb75e
parent dac4d7de3b95eecb1d879c83090ae284dc6febac
Author: Russ Cox <rsc@swtch.com>
Date:   Thu, 10 Jul 2008 10:07:46 -0400

libvxc: use own isnan in vfprintf

Diffstat:
src/libvxc/bsdstdio/vfprintf.c | 4+++-
src/libvxc/msun/s_isnan.c | 4+---
2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/libvxc/bsdstdio/vfprintf.c b/src/libvxc/bsdstdio/vfprintf.c @@ -37,6 +37,8 @@ #define FLOATING_POINT 1 #include <math.h> +extern int vx32_isnan(double); + #if defined(LIBC_SCCS) && !defined(lint) static char *rcsid = "$OpenBSD: vfprintf.c,v 1.8 1998/08/14 21:39:42 deraadt Exp $"; #endif /* LIBC_SCCS and not lint */ @@ -484,7 +486,7 @@ reswitch: switch (ch) { size = 3; break; } - if (isnan(_double)) { + if (vx32_isnan(_double)) { cp = "NaN"; size = 3; break; diff --git a/src/libvxc/msun/s_isnan.c b/src/libvxc/msun/s_isnan.c @@ -31,16 +31,14 @@ #include "math_private.h" /* Provided by libc */ -#if 0 int -isnan(double d) +vx32_isnan(double d) { union IEEEd2bits u; u.d = d; return (u.bits.exp == 2047 && (u.bits.manl != 0 || u.bits.manh != 0)); } -#endif int isnanf(float f)