[PATCH 4/9] msvcr120: If erff is not available, fall back to erf.
Alex Henrie
alexhenrie24 at gmail.com
Sun Jul 9 23:55:05 CDT 2017
erf is part of the SVr4 and 4.3BSD standards but erff is not. In other
words, some systems have erf but not erff.
Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
---
dlls/msvcrt/math.c | 21 ++++++++++-----------
1 file changed, 10 insertions(+), 11 deletions(-)
diff --git a/dlls/msvcrt/math.c b/dlls/msvcrt/math.c
index f9d1d3ecde..c5a6dbd215 100644
--- a/dlls/msvcrt/math.c
+++ b/dlls/msvcrt/math.c
@@ -2733,28 +2733,27 @@ short CDECL MSVCR120__ldtest(LDOUBLE *x)
}
/*********************************************************************
- * erff (MSVCR120.@)
+ * erf (MSVCR120.@)
*/
-float CDECL MSVCR120_erff(float x)
+double CDECL MSVCR120_erf(double x)
{
-#ifdef HAVE_ERFF
- return erff(x);
+#ifdef HAVE_ERF
+ return erf(x);
#else
FIXME( "not implemented\n" );
- return 0.0f;
+ return 0.0;
#endif
}
/*********************************************************************
- * erf (MSVCR120.@)
+ * erff (MSVCR120.@)
*/
-double CDECL MSVCR120_erf(double x)
+float CDECL MSVCR120_erff(float x)
{
-#ifdef HAVE_ERF
- return erf(x);
+#ifdef HAVE_ERFF
+ return erff(x);
#else
- FIXME( "not implemented\n" );
- return 0.0;
+ return MSVCR120_erf(x);
#endif
}
--
2.13.2
More information about the wine-patches
mailing list