diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-13 14:07:37 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-13 14:07:37 +0000 |
commit | de1caa20c41f730e54fb6974ba7821fe48816e40 (patch) | |
tree | 4702bdab12e2b6f51bef05af9f8d8854d2e1b7e8 /src/util.c | |
parent | Adding upstream version 3.45.1. (diff) | |
download | sqlite3-de1caa20c41f730e54fb6974ba7821fe48816e40.tar.xz sqlite3-de1caa20c41f730e54fb6974ba7821fe48816e40.zip |
Adding upstream version 3.45.2.upstream/3.45.2
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/util.c')
-rw-r--r-- | src/util.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -627,6 +627,9 @@ do_atof_calc: u64 s2; rr[0] = (double)s; s2 = (u64)rr[0]; +#if defined(_MSC_VER) && _MSC_VER<1700 + if( s2==0x8000000000000000LL ){ s2 = 2*(u64)(0.5*rr[0]); } +#endif rr[1] = s>=s2 ? (double)(s - s2) : -(double)(s2 - s); if( e>0 ){ while( e>=100 ){ @@ -1069,7 +1072,7 @@ void sqlite3FpDecode(FpDecode *p, double r, int iRound, int mxRound){ assert( p->n>0 ); assert( p->n<sizeof(p->zBuf) ); p->iDP = p->n + exp; - if( iRound<0 ){ + if( iRound<=0 ){ iRound = p->iDP - iRound; if( iRound==0 && p->zBuf[i+1]>='5' ){ iRound = 1; |