Fossil SCM

The SQLite trunk version added at [1ec45d0dea0fca98] contains an important bug, that probably does not affect Fossil, but it seems good to update again just in case.

drh 2026-08-04 20:44 UTC trunk
Commit 358b58c1d78acf93e1e204588cf3aa3aa285e9410d529f2b5bdb55236ea1353e
2 files changed +16 -9 +2 -2
+16 -9
--- extsrc/sqlite3.c
+++ extsrc/sqlite3.c
@@ -16,11 +16,11 @@
1616
** if you want a wrapper to interface SQLite with your choice of programming
1717
** language. The code for the "sqlite3" command-line shell is also in a
1818
** separate file. This file contains only code for the core SQLite library.
1919
**
2020
** The content in this amalgamation comes from Fossil check-in
21
-** bdc841de10fef65b627deb8b770702c97617 with changes in files:
21
+** 6bdfff7ddb63d0b4f28f6c174a36e81486a6 with changes in files:
2222
**
2323
**
2424
*/
2525
#ifndef SQLITE_AMALGAMATION
2626
#define SQLITE_CORE 1
@@ -467,14 +467,14 @@
467467
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
468468
** [sqlite_version()] and [sqlite_source_id()].
469469
*/
470470
#define SQLITE_VERSION "3.54.0"
471471
#define SQLITE_VERSION_NUMBER 3054000
472
-#define SQLITE_SOURCE_ID "2026-08-04 14:55:51 bdc841de10fef65b627deb8b770702c976174a66af847c96ebecf24d91798744"
472
+#define SQLITE_SOURCE_ID "2026-08-04 20:40:10 6bdfff7ddb63d0b4f28f6c174a36e81486a652056a4e21644378a22feda780fd"
473473
#define SQLITE_SCM_BRANCH "trunk"
474474
#define SQLITE_SCM_TAGS ""
475
-#define SQLITE_SCM_DATETIME "2026-08-04T14:55:51.598Z"
475
+#define SQLITE_SCM_DATETIME "2026-08-04T20:40:10.440Z"
476476
477477
/*
478478
** CAPI3REF: Run-Time Library Version Numbers
479479
** KEYWORDS: sqlite3_version sqlite3_sourceid
480480
**
@@ -106966,14 +106966,21 @@
106966106966
const void *pKey1, int nKey1, /* Left side of comparison */
106967106967
const void *pKey2, int nKey2 /* Right side of comparison */
106968106968
){
106969106969
const u8 * const p1 = (const u8 * const)pKey1;
106970106970
const u8 * const p2 = (const u8 * const)pKey2;
106971
- double r1 = vdbeSorterGetReal(p1);
106972
- double r2 = vdbeSorterGetReal(p2);
106973
- return vdbeSorterFinishRealCompare(pTask,pbKey2Cached,
106974
- pKey1,nKey1,pKey2,nKey2,r1,r2);
106971
+ if( p1[1]==6 || p2[1]==6 ){
106972
+ /* 64-bit integer values cannot be represented exactly by a double so
106973
+ ** must be handled by the generalized comparison function. */
106974
+ return vdbeSorterCompare(pTask,
106975
+ pbKey2Cached, pKey1,nKey1, pKey2,nKey2);
106976
+ }else{
106977
+ double r1 = vdbeSorterGetReal(p1);
106978
+ double r2 = vdbeSorterGetReal(p2);
106979
+ return vdbeSorterFinishRealCompare(pTask,pbKey2Cached,
106980
+ pKey1,nKey1,pKey2,nKey2,r1,r2);
106981
+ }
106975106982
}
106976106983
106977106984
/*
106978106985
** Comparison function optimized for the case where the first term
106979106986
** of both keys are either MEM_Real or MEM_RealInt.
@@ -106997,12 +107004,12 @@
106997107004
assert( p1[0]<0x80 && p2[0]<0x80 ); /* 1-byte headers: nAllField<13 */
106998107005
assert( p1[1]>0 && p1[1]<10 ); /* first field guaranteed numeric */
106999107006
assert( p2[1]>0 && p2[1]<10 ); /* first field guaranteed numeric */
107000107007
107001107008
if( p1[1]!=7 || p2[1]!=7 ){
107002
- /* One or both floating point values are stored as INTEGER (MEM_RealInt).
107003
- ** Handle this case separately for efficiency */
107009
+ /* One or both floating point values are stored as INTEGER. This might
107010
+ ** be because of the MEM_RealInt encoding. Try to optimize that case. */
107004107011
return vdbeSorterCompareRealInt(pTask,
107005107012
pbKey2Cached, pKey1,nKey1, pKey2,nKey2
107006107013
);
107007107014
}
107008107015
assert( p1[0]<=nKey1-8 && p2[0]<=nKey2-8 );
107009107016
--- extsrc/sqlite3.c
+++ extsrc/sqlite3.c
@@ -16,11 +16,11 @@
16 ** if you want a wrapper to interface SQLite with your choice of programming
17 ** language. The code for the "sqlite3" command-line shell is also in a
18 ** separate file. This file contains only code for the core SQLite library.
19 **
20 ** The content in this amalgamation comes from Fossil check-in
21 ** bdc841de10fef65b627deb8b770702c97617 with changes in files:
22 **
23 **
24 */
25 #ifndef SQLITE_AMALGAMATION
26 #define SQLITE_CORE 1
@@ -467,14 +467,14 @@
467 ** [sqlite3_libversion_number()], [sqlite3_sourceid()],
468 ** [sqlite_version()] and [sqlite_source_id()].
469 */
470 #define SQLITE_VERSION "3.54.0"
471 #define SQLITE_VERSION_NUMBER 3054000
472 #define SQLITE_SOURCE_ID "2026-08-04 14:55:51 bdc841de10fef65b627deb8b770702c976174a66af847c96ebecf24d91798744"
473 #define SQLITE_SCM_BRANCH "trunk"
474 #define SQLITE_SCM_TAGS ""
475 #define SQLITE_SCM_DATETIME "2026-08-04T14:55:51.598Z"
476
477 /*
478 ** CAPI3REF: Run-Time Library Version Numbers
479 ** KEYWORDS: sqlite3_version sqlite3_sourceid
480 **
@@ -106966,14 +106966,21 @@
106966 const void *pKey1, int nKey1, /* Left side of comparison */
106967 const void *pKey2, int nKey2 /* Right side of comparison */
106968 ){
106969 const u8 * const p1 = (const u8 * const)pKey1;
106970 const u8 * const p2 = (const u8 * const)pKey2;
106971 double r1 = vdbeSorterGetReal(p1);
106972 double r2 = vdbeSorterGetReal(p2);
106973 return vdbeSorterFinishRealCompare(pTask,pbKey2Cached,
106974 pKey1,nKey1,pKey2,nKey2,r1,r2);
 
 
 
 
 
 
 
106975 }
106976
106977 /*
106978 ** Comparison function optimized for the case where the first term
106979 ** of both keys are either MEM_Real or MEM_RealInt.
@@ -106997,12 +107004,12 @@
106997 assert( p1[0]<0x80 && p2[0]<0x80 ); /* 1-byte headers: nAllField<13 */
106998 assert( p1[1]>0 && p1[1]<10 ); /* first field guaranteed numeric */
106999 assert( p2[1]>0 && p2[1]<10 ); /* first field guaranteed numeric */
107000
107001 if( p1[1]!=7 || p2[1]!=7 ){
107002 /* One or both floating point values are stored as INTEGER (MEM_RealInt).
107003 ** Handle this case separately for efficiency */
107004 return vdbeSorterCompareRealInt(pTask,
107005 pbKey2Cached, pKey1,nKey1, pKey2,nKey2
107006 );
107007 }
107008 assert( p1[0]<=nKey1-8 && p2[0]<=nKey2-8 );
107009
--- extsrc/sqlite3.c
+++ extsrc/sqlite3.c
@@ -16,11 +16,11 @@
16 ** if you want a wrapper to interface SQLite with your choice of programming
17 ** language. The code for the "sqlite3" command-line shell is also in a
18 ** separate file. This file contains only code for the core SQLite library.
19 **
20 ** The content in this amalgamation comes from Fossil check-in
21 ** 6bdfff7ddb63d0b4f28f6c174a36e81486a6 with changes in files:
22 **
23 **
24 */
25 #ifndef SQLITE_AMALGAMATION
26 #define SQLITE_CORE 1
@@ -467,14 +467,14 @@
467 ** [sqlite3_libversion_number()], [sqlite3_sourceid()],
468 ** [sqlite_version()] and [sqlite_source_id()].
469 */
470 #define SQLITE_VERSION "3.54.0"
471 #define SQLITE_VERSION_NUMBER 3054000
472 #define SQLITE_SOURCE_ID "2026-08-04 20:40:10 6bdfff7ddb63d0b4f28f6c174a36e81486a652056a4e21644378a22feda780fd"
473 #define SQLITE_SCM_BRANCH "trunk"
474 #define SQLITE_SCM_TAGS ""
475 #define SQLITE_SCM_DATETIME "2026-08-04T20:40:10.440Z"
476
477 /*
478 ** CAPI3REF: Run-Time Library Version Numbers
479 ** KEYWORDS: sqlite3_version sqlite3_sourceid
480 **
@@ -106966,14 +106966,21 @@
106966 const void *pKey1, int nKey1, /* Left side of comparison */
106967 const void *pKey2, int nKey2 /* Right side of comparison */
106968 ){
106969 const u8 * const p1 = (const u8 * const)pKey1;
106970 const u8 * const p2 = (const u8 * const)pKey2;
106971 if( p1[1]==6 || p2[1]==6 ){
106972 /* 64-bit integer values cannot be represented exactly by a double so
106973 ** must be handled by the generalized comparison function. */
106974 return vdbeSorterCompare(pTask,
106975 pbKey2Cached, pKey1,nKey1, pKey2,nKey2);
106976 }else{
106977 double r1 = vdbeSorterGetReal(p1);
106978 double r2 = vdbeSorterGetReal(p2);
106979 return vdbeSorterFinishRealCompare(pTask,pbKey2Cached,
106980 pKey1,nKey1,pKey2,nKey2,r1,r2);
106981 }
106982 }
106983
106984 /*
106985 ** Comparison function optimized for the case where the first term
106986 ** of both keys are either MEM_Real or MEM_RealInt.
@@ -106997,12 +107004,12 @@
107004 assert( p1[0]<0x80 && p2[0]<0x80 ); /* 1-byte headers: nAllField<13 */
107005 assert( p1[1]>0 && p1[1]<10 ); /* first field guaranteed numeric */
107006 assert( p2[1]>0 && p2[1]<10 ); /* first field guaranteed numeric */
107007
107008 if( p1[1]!=7 || p2[1]!=7 ){
107009 /* One or both floating point values are stored as INTEGER. This might
107010 ** be because of the MEM_RealInt encoding. Try to optimize that case. */
107011 return vdbeSorterCompareRealInt(pTask,
107012 pbKey2Cached, pKey1,nKey1, pKey2,nKey2
107013 );
107014 }
107015 assert( p1[0]<=nKey1-8 && p2[0]<=nKey2-8 );
107016
--- extsrc/sqlite3.h
+++ extsrc/sqlite3.h
@@ -146,14 +146,14 @@
146146
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
147147
** [sqlite_version()] and [sqlite_source_id()].
148148
*/
149149
#define SQLITE_VERSION "3.54.0"
150150
#define SQLITE_VERSION_NUMBER 3054000
151
-#define SQLITE_SOURCE_ID "2026-08-04 14:55:51 bdc841de10fef65b627deb8b770702c976174a66af847c96ebecf24d91798744"
151
+#define SQLITE_SOURCE_ID "2026-08-04 20:40:10 6bdfff7ddb63d0b4f28f6c174a36e81486a652056a4e21644378a22feda780fd"
152152
#define SQLITE_SCM_BRANCH "trunk"
153153
#define SQLITE_SCM_TAGS ""
154
-#define SQLITE_SCM_DATETIME "2026-08-04T14:55:51.598Z"
154
+#define SQLITE_SCM_DATETIME "2026-08-04T20:40:10.440Z"
155155
156156
/*
157157
** CAPI3REF: Run-Time Library Version Numbers
158158
** KEYWORDS: sqlite3_version sqlite3_sourceid
159159
**
160160
--- extsrc/sqlite3.h
+++ extsrc/sqlite3.h
@@ -146,14 +146,14 @@
146 ** [sqlite3_libversion_number()], [sqlite3_sourceid()],
147 ** [sqlite_version()] and [sqlite_source_id()].
148 */
149 #define SQLITE_VERSION "3.54.0"
150 #define SQLITE_VERSION_NUMBER 3054000
151 #define SQLITE_SOURCE_ID "2026-08-04 14:55:51 bdc841de10fef65b627deb8b770702c976174a66af847c96ebecf24d91798744"
152 #define SQLITE_SCM_BRANCH "trunk"
153 #define SQLITE_SCM_TAGS ""
154 #define SQLITE_SCM_DATETIME "2026-08-04T14:55:51.598Z"
155
156 /*
157 ** CAPI3REF: Run-Time Library Version Numbers
158 ** KEYWORDS: sqlite3_version sqlite3_sourceid
159 **
160
--- extsrc/sqlite3.h
+++ extsrc/sqlite3.h
@@ -146,14 +146,14 @@
146 ** [sqlite3_libversion_number()], [sqlite3_sourceid()],
147 ** [sqlite_version()] and [sqlite_source_id()].
148 */
149 #define SQLITE_VERSION "3.54.0"
150 #define SQLITE_VERSION_NUMBER 3054000
151 #define SQLITE_SOURCE_ID "2026-08-04 20:40:10 6bdfff7ddb63d0b4f28f6c174a36e81486a652056a4e21644378a22feda780fd"
152 #define SQLITE_SCM_BRANCH "trunk"
153 #define SQLITE_SCM_TAGS ""
154 #define SQLITE_SCM_DATETIME "2026-08-04T20:40:10.440Z"
155
156 /*
157 ** CAPI3REF: Run-Time Library Version Numbers
158 ** KEYWORDS: sqlite3_version sqlite3_sourceid
159 **
160

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button