Skip to content

Release/v3.47.1 #46

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions source/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## SQLite Release 3.47.1 On 2024-11-25

1. Fix the makefiles so that they once again honored DESTDIR for the "install" target.
2. Add the SQLITE_IOCAP_SUBPAGE_READ capability to the VFS, to work around issues on some non-standard VFSes caused by making SQLITE_DIRECT_OVERFLOW_READ the default in version 3.45.0.
3. Fix problems with line endings in the new sqlite3_rsync.exe utility on Windows.
4. Fix incorrect answers to certain obscure IN queries caused by new query optimizations added in the 3.47.0 release.
5. Other minor bug fixes.

## SQLite Release 3.47.0 On 2024-10-21

1. Allow arbitrary expressions in the second argument to the RAISE function.
Expand Down
16 changes: 8 additions & 8 deletions source/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
Download: https://sqlite.org/2024/sqlite-amalgamation-3470000.zip
Download: https://sqlite.org/2024/sqlite-amalgamation-3470100.zip

```
Archive: sqlite-amalgamation-3470000.zip
Archive: sqlite-amalgamation-3470100.zip
Length Method Size Cmpr Date Time CRC-32 Name
-------- ------ ------- ---- ---------- ----- -------- ----
0 Stored 0 0% 2024-10-21 18:48 00000000 sqlite-amalgamation-3470000/
9193275 Defl:N 2367775 74% 2024-10-21 18:48 771e2638 sqlite-amalgamation-3470000/sqlite3.c
1044127 Defl:N 267023 74% 2024-10-21 18:48 c073b82b sqlite-amalgamation-3470000/shell.c
650689 Defl:N 168160 74% 2024-10-21 18:48 33ab194f sqlite-amalgamation-3470000/sqlite3.h
38149 Defl:N 6615 83% 2024-10-21 18:48 c5ea7fc8 sqlite-amalgamation-3470000/sqlite3ext.h
0 Stored 0 0% 2024-11-25 14:55 00000000 sqlite-amalgamation-3470100/
9195316 Defl:N 2368442 74% 2024-11-25 14:55 9447f8cd sqlite-amalgamation-3470100/sqlite3.c
1044254 Defl:N 267036 74% 2024-11-25 14:55 95272fac sqlite-amalgamation-3470100/shell.c
651186 Defl:N 168326 74% 2024-11-25 14:55 ab5341bd sqlite-amalgamation-3470100/sqlite3.h
38149 Defl:N 6615 83% 2024-11-25 14:55 c5ea7fc8 sqlite-amalgamation-3470100/sqlite3ext.h
-------- ------- --- -------
10926240 2809573 74% 5 files
10928905 2810419 74% 5 files
```
17 changes: 10 additions & 7 deletions source/shell.c
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ char *sqlite3_fgets(char *buf, int sz, FILE *in){
** that into UTF-8. Otherwise, non-ASCII characters all get translated
** into '?'.
*/
wchar_t *b1 = malloc( sz*sizeof(wchar_t) );
wchar_t *b1 = sqlite3_malloc( sz*sizeof(wchar_t) );
if( b1==0 ) return 0;
_setmode(_fileno(in), IsConsole(in) ? _O_WTEXT : _O_U8TEXT);
if( fgetws(b1, sz/4, in)==0 ){
Expand Down Expand Up @@ -526,7 +526,7 @@ int sqlite3_fputs(const char *z, FILE *out){
** use O_U8TEXT for everything in text mode.
*/
int sz = (int)strlen(z);
wchar_t *b1 = malloc( (sz+1)*sizeof(wchar_t) );
wchar_t *b1 = sqlite3_malloc( (sz+1)*sizeof(wchar_t) );
if( b1==0 ) return 0;
sz = MultiByteToWideChar(CP_UTF8, 0, z, sz, b1, sz);
b1[sz] = 0;
Expand Down Expand Up @@ -6833,31 +6833,37 @@ static int seriesBestIndex(
continue;
}
if( pConstraint->iColumn<SERIES_COLUMN_START ){
if( pConstraint->iColumn==SERIES_COLUMN_VALUE ){
if( pConstraint->iColumn==SERIES_COLUMN_VALUE && pConstraint->usable ){
switch( op ){
case SQLITE_INDEX_CONSTRAINT_EQ:
case SQLITE_INDEX_CONSTRAINT_IS: {
idxNum |= 0x0080;
idxNum &= ~0x3300;
aIdx[5] = i;
aIdx[6] = -1;
#ifndef ZERO_ARGUMENT_GENERATE_SERIES
bStartSeen = 1;
#endif
break;
}
case SQLITE_INDEX_CONSTRAINT_GE: {
if( idxNum & 0x0080 ) break;
idxNum |= 0x0100;
idxNum &= ~0x0200;
aIdx[5] = i;
#ifndef ZERO_ARGUMENT_GENERATE_SERIES
bStartSeen = 1;
#endif
break;
}
case SQLITE_INDEX_CONSTRAINT_GT: {
if( idxNum & 0x0080 ) break;
idxNum |= 0x0200;
idxNum &= ~0x0100;
aIdx[5] = i;
#ifndef ZERO_ARGUMENT_GENERATE_SERIES
bStartSeen = 1;
#endif
break;
}
case SQLITE_INDEX_CONSTRAINT_LE: {
Expand Down Expand Up @@ -14169,7 +14175,7 @@ static int idxCreateVtabSchema(sqlite3expert *p, char **pzErrmsg){
}else{
IdxTable *pTab;
rc = idxGetTableInfo(p->db, zName, &pTab, pzErrmsg);
if( rc==SQLITE_OK ){
if( rc==SQLITE_OK && ALWAYS(pTab!=0) ){
int i;
char *zInner = 0;
char *zOuter = 0;
Expand Down Expand Up @@ -31840,7 +31846,6 @@ static QuickScanState quickscan(char *zLine, QuickScanState qss,
char cWait = (char)qss; /* intentional narrowing loss */
if( cWait==0 ){
PlainScan:
assert( cWait==0 );
while( (cin = *zLine++)!=0 ){
if( IsSpace(cin) )
continue;
Expand Down Expand Up @@ -31892,7 +31897,6 @@ static QuickScanState quickscan(char *zLine, QuickScanState qss,
if( *zLine != '/' )
continue;
++zLine;
cWait = 0;
CONTINUE_PROMPT_AWAITC(pst, 0);
qss = QSS_SETV(qss, 0);
goto PlainScan;
Expand All @@ -31904,7 +31908,6 @@ static QuickScanState quickscan(char *zLine, QuickScanState qss,
}
deliberate_fall_through;
case ']':
cWait = 0;
CONTINUE_PROMPT_AWAITC(pst, 0);
qss = QSS_SETV(qss, 0);
goto PlainScan;
Expand Down
Loading