mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-01-29 21:46:59 +03:00
MSVC fix
This commit is contained in:
parent
cc146db32c
commit
3157b34bb3
@ -1,3 +1,7 @@
|
||||
Fri Jun 22 16:39:36 CEST 2001 Bjorn Reese <breese@users.sourceforge.net>
|
||||
|
||||
* trio.c: MSVC fix (provided by Igor Zlatkovic)
|
||||
|
||||
Fri Jun 22 12:42:16 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
|
||||
|
||||
* include/win32config.h: another small fix for ATTRIBUTE_UNUSED
|
||||
|
10
trio.c
10
trio.c
@ -788,6 +788,12 @@ TrioIsQualifier(const char ch)
|
||||
* warnings about divide by zero, and others will simply fail to
|
||||
* generate a NaN.
|
||||
*/
|
||||
static double
|
||||
TrioDivide(double dividend, double divisor)
|
||||
{
|
||||
return dividend / divisor;
|
||||
}
|
||||
|
||||
static double
|
||||
TrioGenerateNaN(void)
|
||||
{
|
||||
@ -800,11 +806,11 @@ TrioGenerateNaN(void)
|
||||
void (*signal_handler)(int);
|
||||
|
||||
signal_handler = signal(SIGFPE, SIG_IGN);
|
||||
value = 0.0 / 0.0;
|
||||
value = TrioDivide(0.0, 0.0);
|
||||
signal(SIGFPE, signal_handler);
|
||||
return value;
|
||||
#else
|
||||
return 0.0 / 0.0;
|
||||
return TrioDivide(0.0, 0.0);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user