SQLite

Check-in [b3cfe23b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Restore the use of system isnan() that was removed by check-in [ea748edecb261f2b]. See forum thread d7c530ac587f59e6.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: b3cfe23bec0b95ca673802526704200e2396df715fdded72aa71addd7f47e0e1
User & Date: drh 2021-09-06 11:44:19
Context
2021-09-06
15:59
Fix an issue in the "shrink.test" test script reported by forum post 90a74bd618. (check-in: 6c3734ed user: drh tags: trunk)
11:44
Restore the use of system isnan() that was removed by check-in [ea748edecb261f2b]. See forum thread d7c530ac587f59e6. (check-in: b3cfe23b user: drh tags: trunk)
2021-09-03
18:11
Fix an assertion fault in pcache introduced by [4bc93658aa563f2f] and detected by OSSFuzz. Test case in TH3. (check-in: 2262a494 user: drh tags: trunk)
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/util.c.

56
57
58
59
60
61
62



63
64


65
66





67
68
69
70
71
72
73
74
  return xCallback ? xCallback(iTest) : SQLITE_OK;
}
#endif

#ifndef SQLITE_OMIT_FLOATING_POINT
/*
** Return true if the floating point value is Not a Number (NaN).



*/
int sqlite3IsNaN(double x){


  u64 y;
  memcpy(&y,&x,sizeof(y));





  return IsNaN(y);
}
#endif /* SQLITE_OMIT_FLOATING_POINT */

/*
** Compute a string length that is limited to what can be stored in
** lower 30 bits of a 32-bit signed integer.
**







>
>
>


>
>


>
>
>
>
>
|







56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
  return xCallback ? xCallback(iTest) : SQLITE_OK;
}
#endif

#ifndef SQLITE_OMIT_FLOATING_POINT
/*
** Return true if the floating point value is Not a Number (NaN).
**
** Use the math library isnan() function if compiled with SQLITE_HAVE_ISNAN.
** Otherwise, we have our own implementation that works on most systems.
*/
int sqlite3IsNaN(double x){
  int rc;   /* The value return */
#if !SQLITE_HAVE_ISNAN && !HAVE_ISNAN
  u64 y;
  memcpy(&y,&x,sizeof(y));
  rc = IsNaN(y);
#else
  rc = isnan(x);
#endif /* HAVE_ISNAN */
  testcase( rc );
  return rc;
}
#endif /* SQLITE_OMIT_FLOATING_POINT */

/*
** Compute a string length that is limited to what can be stored in
** lower 30 bits of a 32-bit signed integer.
**