Skip to content

Commit 254046b

Browse files
committed
Merge sqlite-release(3.41.2) into prerelease-integration
2 parents b3de569 + 340f146 commit 254046b

31 files changed

Lines changed: 373 additions & 97 deletions

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.41.1
1+
3.41.2

autoconf/tea/configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ dnl to configure the system for the local environment.
1919
# so that we create the export library with the dll.
2020
#-----------------------------------------------------------------------
2121

22-
AC_INIT([sqlite],[3.41.0])
22+
AC_INIT([sqlite],[3.41.2])
2323

2424
#--------------------------------------------------------------------
2525
# Call TEA_INIT as the first TEA_ macro to set up initial vars.

configure

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! /bin/sh
22
# Guess values for system-dependent variables and create Makefiles.
3-
# Generated by GNU Autoconf 2.69 for sqlcipher 3.41.1.
3+
# Generated by GNU Autoconf 2.69 for sqlcipher 3.41.2.
44
#
55
#
66
# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
@@ -587,8 +587,8 @@ MAKEFLAGS=
587587
# Identity of this package.
588588
PACKAGE_NAME='sqlcipher'
589589
PACKAGE_TARNAME='sqlcipher'
590-
PACKAGE_VERSION='3.41.1'
591-
PACKAGE_STRING='sqlcipher 3.41.1'
590+
PACKAGE_VERSION='3.41.2'
591+
PACKAGE_STRING='sqlcipher 3.41.2'
592592
PACKAGE_BUGREPORT=''
593593
PACKAGE_URL=''
594594

@@ -1354,7 +1354,7 @@ if test "$ac_init_help" = "long"; then
13541354
# Omit some internal or obsolete options to make the list less imposing.
13551355
# This message is too long to be a string in the A/UX 3.1 sh.
13561356
cat <<_ACEOF
1357-
\`configure' configures sqlcipher 3.41.1 to adapt to many kinds of systems.
1357+
\`configure' configures sqlcipher 3.41.2 to adapt to many kinds of systems.
13581358
13591359
Usage: $0 [OPTION]... [VAR=VALUE]...
13601360
@@ -1420,7 +1420,7 @@ fi
14201420

14211421
if test -n "$ac_init_help"; then
14221422
case $ac_init_help in
1423-
short | recursive ) echo "Configuration of sqlcipher 3.41.1:";;
1423+
short | recursive ) echo "Configuration of sqlcipher 3.41.2:";;
14241424
esac
14251425
cat <<\_ACEOF
14261426
@@ -1562,7 +1562,7 @@ fi
15621562
test -n "$ac_init_help" && exit $ac_status
15631563
if $ac_init_version; then
15641564
cat <<\_ACEOF
1565-
sqlcipher configure 3.41.1
1565+
sqlcipher configure 3.41.2
15661566
generated by GNU Autoconf 2.69
15671567
15681568
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1981,7 +1981,7 @@ cat >config.log <<_ACEOF
19811981
This file contains any messages produced by compilers while
19821982
running configure, to aid debugging if configure makes a mistake.
19831983
1984-
It was created by sqlcipher $as_me 3.41.1, which was
1984+
It was created by sqlcipher $as_me 3.41.2, which was
19851985
generated by GNU Autoconf 2.69. Invocation command line was
19861986
19871987
$ $0 $@
@@ -14086,7 +14086,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1408614086
# report actual input values of CONFIG_FILES etc. instead of their
1408714087
# values after options handling.
1408814088
ac_log="
14089-
This file was extended by sqlcipher $as_me 3.41.1, which was
14089+
This file was extended by sqlcipher $as_me 3.41.2, which was
1409014090
generated by GNU Autoconf 2.69. Invocation command line was
1409114091
1409214092
CONFIG_FILES = $CONFIG_FILES
@@ -14152,7 +14152,7 @@ _ACEOF
1415214152
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1415314153
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1415414154
ac_cs_version="\\
14155-
sqlcipher config.status 3.41.1
14155+
sqlcipher config.status 3.41.2
1415614156
configured by $0, generated by GNU Autoconf 2.69,
1415714157
with options \\"\$ac_cs_config\\"
1415814158

ext/fts3/fts3_write.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2667,16 +2667,18 @@ static int fts3MsrBufferData(
26672667
char *pList,
26682668
i64 nList
26692669
){
2670-
if( nList>pMsr->nBuffer ){
2670+
if( (nList+FTS3_NODE_PADDING)>pMsr->nBuffer ){
26712671
char *pNew;
2672-
pMsr->nBuffer = nList*2;
2673-
pNew = (char *)sqlite3_realloc64(pMsr->aBuffer, pMsr->nBuffer);
2672+
int nNew = nList*2 + FTS3_NODE_PADDING;
2673+
pNew = (char *)sqlite3_realloc64(pMsr->aBuffer, nNew);
26742674
if( !pNew ) return SQLITE_NOMEM;
26752675
pMsr->aBuffer = pNew;
2676+
pMsr->nBuffer = nNew;
26762677
}
26772678

26782679
assert( nList>0 );
26792680
memcpy(pMsr->aBuffer, pList, nList);
2681+
memset(&pMsr->aBuffer[nList], 0, FTS3_NODE_PADDING);
26802682
return SQLITE_OK;
26812683
}
26822684

ext/recover/dbdata.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -512,10 +512,14 @@ static int dbdataNext(sqlite3_vtab_cursor *pCursor){
512512
if( pCsr->bOnePage==0 && pCsr->iPgno>pCsr->szDb ) return SQLITE_OK;
513513
rc = dbdataLoadPage(pCsr, pCsr->iPgno, &pCsr->aPage, &pCsr->nPage);
514514
if( rc!=SQLITE_OK ) return rc;
515-
if( pCsr->aPage ) break;
515+
if( pCsr->aPage && pCsr->nPage>=256 ) break;
516+
sqlite3_free(pCsr->aPage);
517+
pCsr->aPage = 0;
516518
if( pCsr->bOnePage ) return SQLITE_OK;
517519
pCsr->iPgno++;
518520
}
521+
522+
assert( iOff+3+2<=pCsr->nPage );
519523
pCsr->iCell = pTab->bPtr ? -2 : 0;
520524
pCsr->nCell = get_uint16(&pCsr->aPage[iOff+3]);
521525
}
@@ -750,8 +754,7 @@ static int dbdataGetEncoding(DbdataCursor *pCsr){
750754
int nPg1 = 0;
751755
u8 *aPg1 = 0;
752756
rc = dbdataLoadPage(pCsr, 1, &aPg1, &nPg1);
753-
assert( rc!=SQLITE_OK || nPg1==0 || nPg1>=512 );
754-
if( rc==SQLITE_OK && nPg1>0 ){
757+
if( rc==SQLITE_OK && nPg1>=(56+4) ){
755758
pCsr->enc = get_uint32(&aPg1[56]);
756759
}
757760
sqlite3_free(aPg1);

0 commit comments

Comments
 (0)