mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-08 14:02:16 +03:00
Merge the latest trunk changes into the sessions branch.
FossilOrigin-Name: f3d148e0d10e16cd744ec88a2961fd617368c5ed
This commit is contained in:
24
Makefile.msc
24
Makefile.msc
@@ -26,7 +26,7 @@ BCC = cl.exe -O2
|
|||||||
# will run on the target platform. (BCC and TCC are usually the
|
# will run on the target platform. (BCC and TCC are usually the
|
||||||
# same unless your are cross-compiling.)
|
# same unless your are cross-compiling.)
|
||||||
#
|
#
|
||||||
TCC = cl.exe -W3 -O2 -DSQLITE_OS_WIN=1 -I. -I$(TOP)\src
|
TCC = cl.exe -W3 -O2 -DSQLITE_OS_WIN=1 -I. -I$(TOP)\src -fp:precise
|
||||||
|
|
||||||
# The mksqlite3c.tcl and mksqlite3h.tcl scripts will pull in
|
# The mksqlite3c.tcl and mksqlite3h.tcl scripts will pull in
|
||||||
# any extension header files by default. For non-amalgamation
|
# any extension header files by default. For non-amalgamation
|
||||||
@@ -105,8 +105,16 @@ TCC = $(TCC) $(OPTS)
|
|||||||
|
|
||||||
# libtool compile/link
|
# libtool compile/link
|
||||||
LTCOMPILE = $(TCC) -Fo$@
|
LTCOMPILE = $(TCC) -Fo$@
|
||||||
LTLINK = $(TCC) -Fe$@
|
|
||||||
LTLIB = lib.exe
|
LTLIB = lib.exe
|
||||||
|
LTLINK = $(TCC) -Fe$@
|
||||||
|
|
||||||
|
# If a platform was set, force the linker to target that.
|
||||||
|
# Note that the vcvars*.bat family of batch files typically
|
||||||
|
# set this for you. Otherwise, the linker will attempt
|
||||||
|
# to deduce the binary type based on the object files.
|
||||||
|
!IF "$(PLATFORM)"!=""
|
||||||
|
LTLINKOPTS = /MACHINE:$(PLATFORM)
|
||||||
|
!ENDIF
|
||||||
|
|
||||||
# nawk compatible awk.
|
# nawk compatible awk.
|
||||||
NAWK = .\gawk.exe
|
NAWK = .\gawk.exe
|
||||||
@@ -440,8 +448,8 @@ libtclsqlite3.lib: tclsqlite.lo libsqlite3.lib
|
|||||||
|
|
||||||
sqlite3.exe: $(TOP)\src\shell.c libsqlite3.lib sqlite3.h
|
sqlite3.exe: $(TOP)\src\shell.c libsqlite3.lib sqlite3.h
|
||||||
$(LTLINK) $(READLINE_FLAGS) \
|
$(LTLINK) $(READLINE_FLAGS) \
|
||||||
$(TOP)\src\shell.c libsqlite3.lib \
|
$(TOP)\src\shell.c \
|
||||||
$(LIBREADLINE) $(TLIBS)
|
/link $(LTLINKOPTS) libsqlite3.lib $(LIBREADLINE) $(TLIBS)
|
||||||
|
|
||||||
# This target creates a directory named "tsrc" and fills it with
|
# This target creates a directory named "tsrc" and fills it with
|
||||||
# copies of all of the C source code and header files needed to
|
# copies of all of the C source code and header files needed to
|
||||||
@@ -706,7 +714,7 @@ tclsqlite-shell.lo: $(TOP)\src\tclsqlite.c $(HDR)
|
|||||||
|
|
||||||
tclsqlite3.exe: tclsqlite-shell.lo libsqlite3.lib
|
tclsqlite3.exe: tclsqlite-shell.lo libsqlite3.lib
|
||||||
$(LTLINK) tclsqlite-shell.lo \
|
$(LTLINK) tclsqlite-shell.lo \
|
||||||
/link /LIBPATH:$(TCLLIBDIR) libsqlite3.lib $(LIBTCL)
|
/link $(LTLINKOPTS) /LIBPATH:$(TCLLIBDIR) libsqlite3.lib $(LIBTCL)
|
||||||
|
|
||||||
# Rules to build opcodes.c and opcodes.h
|
# Rules to build opcodes.c and opcodes.h
|
||||||
#
|
#
|
||||||
@@ -816,7 +824,8 @@ TESTFIXTURE_SRC = $(TESTSRC) $(TOP)\src\tclsqlite.c $(TESTFIXTURE_SRC1)
|
|||||||
testfixture.exe: $(TESTFIXTURE_SRC) $(HDR)
|
testfixture.exe: $(TESTFIXTURE_SRC) $(HDR)
|
||||||
$(LTLINK) -DSQLITE_NO_SYNC=1 $(TESTFIXTURE_FLAGS) \
|
$(LTLINK) -DSQLITE_NO_SYNC=1 $(TESTFIXTURE_FLAGS) \
|
||||||
-DBUILD_sqlite -I$(TCLINCDIR) \
|
-DBUILD_sqlite -I$(TCLINCDIR) \
|
||||||
$(TESTFIXTURE_SRC) /link /LIBPATH:$(TCLLIBDIR) $(LIBTCL) $(TLIBS)
|
$(TESTFIXTURE_SRC) \
|
||||||
|
/link $(LTLINKOPTS) /LIBPATH:$(TCLLIBDIR) $(LIBTCL) $(TLIBS)
|
||||||
|
|
||||||
fulltest: testfixture.exe sqlite3.exe
|
fulltest: testfixture.exe sqlite3.exe
|
||||||
.\testfixture.exe $(TOP)\test\all.test
|
.\testfixture.exe $(TOP)\test\all.test
|
||||||
@@ -835,7 +844,8 @@ sqlite3_analyzer.exe: $(TESTFIXTURE_SRC) spaceanal_tcl.h
|
|||||||
$(LTLINK) -DTCLSH=2 -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1 \
|
$(LTLINK) -DTCLSH=2 -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1 \
|
||||||
-DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE \
|
-DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE \
|
||||||
-DBUILD_sqlite -I$(TCLINCDIR) \
|
-DBUILD_sqlite -I$(TCLINCDIR) \
|
||||||
$(TESTFIXTURE_SRC) /link /LIBPATH:$(TCLLIBDIR) $(LIBTCL) $(TLIBS)
|
$(TESTFIXTURE_SRC) \
|
||||||
|
/link $(LTLINKOPTS) /LIBPATH:$(TCLLIBDIR) $(LIBTCL) $(TLIBS)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
del /Q *.lo *.lib *.obj sqlite3.exe libsqlite3.lib
|
del /Q *.lo *.lib *.obj sqlite3.exe libsqlite3.lib
|
||||||
|
@@ -75,6 +75,9 @@
|
|||||||
/* Define to 1 if you have the `usleep' function. */
|
/* Define to 1 if you have the `usleep' function. */
|
||||||
#undef HAVE_USLEEP
|
#undef HAVE_USLEEP
|
||||||
|
|
||||||
|
/* Define to 1 if you have the utime() library function. */
|
||||||
|
#undef HAVE_UTIME
|
||||||
|
|
||||||
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
||||||
*/
|
*/
|
||||||
#undef LT_OBJDIR
|
#undef LT_OBJDIR
|
||||||
|
90
configure
vendored
90
configure
vendored
@@ -12145,7 +12145,8 @@ done
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
for ac_func in usleep fdatasync localtime_r gmtime_r localtime_s
|
|
||||||
|
for ac_func in usleep fdatasync localtime_r gmtime_r localtime_s utime
|
||||||
do
|
do
|
||||||
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
|
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
|
||||||
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
|
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
|
||||||
@@ -13440,6 +13441,93 @@ fi
|
|||||||
|
|
||||||
if test "${use_loadextension}" = "yes" ; then
|
if test "${use_loadextension}" = "yes" ; then
|
||||||
OPT_FEATURE_FLAGS=""
|
OPT_FEATURE_FLAGS=""
|
||||||
|
{ $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
|
||||||
|
$as_echo_n "checking for library containing dlopen... " >&6; }
|
||||||
|
if test "${ac_cv_search_dlopen+set}" = set; then
|
||||||
|
$as_echo_n "(cached) " >&6
|
||||||
|
else
|
||||||
|
ac_func_search_save_LIBS=$LIBS
|
||||||
|
cat >conftest.$ac_ext <<_ACEOF
|
||||||
|
/* confdefs.h. */
|
||||||
|
_ACEOF
|
||||||
|
cat confdefs.h >>conftest.$ac_ext
|
||||||
|
cat >>conftest.$ac_ext <<_ACEOF
|
||||||
|
/* end confdefs.h. */
|
||||||
|
|
||||||
|
/* Override any GCC internal prototype to avoid an error.
|
||||||
|
Use char because int might match the return type of a GCC
|
||||||
|
builtin and then its argument prototype would still apply. */
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"
|
||||||
|
#endif
|
||||||
|
char dlopen ();
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
return dlopen ();
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
_ACEOF
|
||||||
|
for ac_lib in '' dl; do
|
||||||
|
if test -z "$ac_lib"; then
|
||||||
|
ac_res="none required"
|
||||||
|
else
|
||||||
|
ac_res=-l$ac_lib
|
||||||
|
LIBS="-l$ac_lib $ac_func_search_save_LIBS"
|
||||||
|
fi
|
||||||
|
rm -f conftest.$ac_objext conftest$ac_exeext
|
||||||
|
if { (ac_try="$ac_link"
|
||||||
|
case "(($ac_try" in
|
||||||
|
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
||||||
|
*) ac_try_echo=$ac_try;;
|
||||||
|
esac
|
||||||
|
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
|
||||||
|
$as_echo "$ac_try_echo") >&5
|
||||||
|
(eval "$ac_link") 2>conftest.er1
|
||||||
|
ac_status=$?
|
||||||
|
grep -v '^ *+' conftest.er1 >conftest.err
|
||||||
|
rm -f conftest.er1
|
||||||
|
cat conftest.err >&5
|
||||||
|
$as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); } && {
|
||||||
|
test -z "$ac_c_werror_flag" ||
|
||||||
|
test ! -s conftest.err
|
||||||
|
} && test -s conftest$ac_exeext && {
|
||||||
|
test "$cross_compiling" = yes ||
|
||||||
|
$as_test_x conftest$ac_exeext
|
||||||
|
}; then
|
||||||
|
ac_cv_search_dlopen=$ac_res
|
||||||
|
else
|
||||||
|
$as_echo "$as_me: failed program was:" >&5
|
||||||
|
sed 's/^/| /' conftest.$ac_ext >&5
|
||||||
|
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
rm -rf conftest.dSYM
|
||||||
|
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
|
||||||
|
conftest$ac_exeext
|
||||||
|
if test "${ac_cv_search_dlopen+set}" = set; then
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
if test "${ac_cv_search_dlopen+set}" = set; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ac_cv_search_dlopen=no
|
||||||
|
fi
|
||||||
|
rm conftest.$ac_ext
|
||||||
|
LIBS=$ac_func_search_save_LIBS
|
||||||
|
fi
|
||||||
|
{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
|
||||||
|
$as_echo "$ac_cv_search_dlopen" >&6; }
|
||||||
|
ac_res=$ac_cv_search_dlopen
|
||||||
|
if test "$ac_res" != no; then
|
||||||
|
test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
else
|
else
|
||||||
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
|
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
|
||||||
fi
|
fi
|
||||||
|
@@ -127,7 +127,7 @@ AC_CHECK_HEADERS([sys/types.h stdlib.h stdint.h inttypes.h])
|
|||||||
#########
|
#########
|
||||||
# Figure out whether or not we have these functions
|
# Figure out whether or not we have these functions
|
||||||
#
|
#
|
||||||
AC_CHECK_FUNCS([usleep fdatasync localtime_r gmtime_r localtime_s])
|
AC_CHECK_FUNCS([usleep fdatasync localtime_r gmtime_r localtime_s utime])
|
||||||
|
|
||||||
#########
|
#########
|
||||||
# By default, we use the amalgamation (this may be changed below...)
|
# By default, we use the amalgamation (this may be changed below...)
|
||||||
@@ -619,6 +619,7 @@ AC_ARG_ENABLE(load-extension, AC_HELP_STRING([--enable-load-extension],
|
|||||||
[use_loadextension=$enableval],[use_loadextension=no])
|
[use_loadextension=$enableval],[use_loadextension=no])
|
||||||
if test "${use_loadextension}" = "yes" ; then
|
if test "${use_loadextension}" = "yes" ; then
|
||||||
OPT_FEATURE_FLAGS=""
|
OPT_FEATURE_FLAGS=""
|
||||||
|
AC_SEARCH_LIBS(dlopen, dl)
|
||||||
else
|
else
|
||||||
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
|
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
|
||||||
fi
|
fi
|
||||||
|
@@ -1094,7 +1094,7 @@ static int fts3InitVtab(
|
|||||||
/* Fill in the azColumn array */
|
/* Fill in the azColumn array */
|
||||||
for(iCol=0; iCol<nCol; iCol++){
|
for(iCol=0; iCol<nCol; iCol++){
|
||||||
char *z;
|
char *z;
|
||||||
int n;
|
int n = 0;
|
||||||
z = (char *)sqlite3Fts3NextToken(aCol[iCol], &n);
|
z = (char *)sqlite3Fts3NextToken(aCol[iCol], &n);
|
||||||
memcpy(zCsr, z, n);
|
memcpy(zCsr, z, n);
|
||||||
zCsr[n] = '\0';
|
zCsr[n] = '\0';
|
||||||
@@ -2680,8 +2680,8 @@ static int fts3SyncMethod(sqlite3_vtab *pVtab){
|
|||||||
** Implementation of xBegin() method. This is a no-op.
|
** Implementation of xBegin() method. This is a no-op.
|
||||||
*/
|
*/
|
||||||
static int fts3BeginMethod(sqlite3_vtab *pVtab){
|
static int fts3BeginMethod(sqlite3_vtab *pVtab){
|
||||||
UNUSED_PARAMETER(pVtab);
|
|
||||||
TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
|
TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
|
||||||
|
UNUSED_PARAMETER(pVtab);
|
||||||
assert( p->pSegments==0 );
|
assert( p->pSegments==0 );
|
||||||
assert( p->nPendingData==0 );
|
assert( p->nPendingData==0 );
|
||||||
assert( p->inTransaction!=1 );
|
assert( p->inTransaction!=1 );
|
||||||
@@ -2696,8 +2696,8 @@ static int fts3BeginMethod(sqlite3_vtab *pVtab){
|
|||||||
** by fts3SyncMethod().
|
** by fts3SyncMethod().
|
||||||
*/
|
*/
|
||||||
static int fts3CommitMethod(sqlite3_vtab *pVtab){
|
static int fts3CommitMethod(sqlite3_vtab *pVtab){
|
||||||
UNUSED_PARAMETER(pVtab);
|
|
||||||
TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
|
TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
|
||||||
|
UNUSED_PARAMETER(pVtab);
|
||||||
assert( p->nPendingData==0 );
|
assert( p->nPendingData==0 );
|
||||||
assert( p->inTransaction!=0 );
|
assert( p->inTransaction!=0 );
|
||||||
assert( p->pSegments==0 );
|
assert( p->pSegments==0 );
|
||||||
@@ -4354,8 +4354,8 @@ int sqlite3Fts3EvalPhraseStats(
|
|||||||
if( pExpr->bDeferred && pExpr->pParent->eType!=FTSQUERY_NEAR ){
|
if( pExpr->bDeferred && pExpr->pParent->eType!=FTSQUERY_NEAR ){
|
||||||
assert( pCsr->nDoc>0 );
|
assert( pCsr->nDoc>0 );
|
||||||
for(iCol=0; iCol<pTab->nColumn; iCol++){
|
for(iCol=0; iCol<pTab->nColumn; iCol++){
|
||||||
aiOut[iCol*3 + 1] = pCsr->nDoc;
|
aiOut[iCol*3 + 1] = (u32)pCsr->nDoc;
|
||||||
aiOut[iCol*3 + 2] = pCsr->nDoc;
|
aiOut[iCol*3 + 2] = (u32)pCsr->nDoc;
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
rc = fts3EvalGatherStats(pCsr, pExpr);
|
rc = fts3EvalGatherStats(pCsr, pExpr);
|
||||||
|
@@ -249,7 +249,7 @@ struct Fts3Cursor {
|
|||||||
u8 bDesc; /* True to sort in descending order */
|
u8 bDesc; /* True to sort in descending order */
|
||||||
int eEvalmode; /* An FTS3_EVAL_XX constant */
|
int eEvalmode; /* An FTS3_EVAL_XX constant */
|
||||||
int nRowAvg; /* Average size of database rows, in pages */
|
int nRowAvg; /* Average size of database rows, in pages */
|
||||||
int nDoc; /* Documents in table */
|
sqlite3_int64 nDoc; /* Documents in table */
|
||||||
|
|
||||||
int isMatchinfoNeeded; /* True when aMatchinfo[] needs filling in */
|
int isMatchinfoNeeded; /* True when aMatchinfo[] needs filling in */
|
||||||
u32 *aMatchinfo; /* Information about most recent match */
|
u32 *aMatchinfo; /* Information about most recent match */
|
||||||
|
@@ -1024,7 +1024,7 @@ static int fts3MatchinfoValues(
|
|||||||
|
|
||||||
case FTS3_MATCHINFO_NDOC:
|
case FTS3_MATCHINFO_NDOC:
|
||||||
if( bGlobal ){
|
if( bGlobal ){
|
||||||
sqlite3_int64 nDoc;
|
sqlite3_int64 nDoc = 0;
|
||||||
rc = fts3MatchinfoSelectDoctotal(pTab, &pSelect, &nDoc, 0);
|
rc = fts3MatchinfoSelectDoctotal(pTab, &pSelect, &nDoc, 0);
|
||||||
pInfo->aMatchinfo[0] = (u32)nDoc;
|
pInfo->aMatchinfo[0] = (u32)nDoc;
|
||||||
}
|
}
|
||||||
|
@@ -21,6 +21,7 @@
|
|||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
typedef struct Fts3termTable Fts3termTable;
|
typedef struct Fts3termTable Fts3termTable;
|
||||||
typedef struct Fts3termCursor Fts3termCursor;
|
typedef struct Fts3termCursor Fts3termCursor;
|
||||||
|
@@ -279,8 +279,6 @@ static int fts3_configure_incr_load_cmd(
|
|||||||
#ifdef SQLITE_ENABLE_FTS3
|
#ifdef SQLITE_ENABLE_FTS3
|
||||||
extern int test_fts3_node_chunksize;
|
extern int test_fts3_node_chunksize;
|
||||||
extern int test_fts3_node_chunk_threshold;
|
extern int test_fts3_node_chunk_threshold;
|
||||||
int iArg1;
|
|
||||||
int iArg2;
|
|
||||||
Tcl_Obj *pRet;
|
Tcl_Obj *pRet;
|
||||||
|
|
||||||
if( objc!=1 && objc!=3 ){
|
if( objc!=1 && objc!=3 ){
|
||||||
|
@@ -156,7 +156,7 @@ int sqlite3Fts3InitTokenizer(
|
|||||||
){
|
){
|
||||||
int rc;
|
int rc;
|
||||||
char *z = (char *)zArg;
|
char *z = (char *)zArg;
|
||||||
int n;
|
int n = 0;
|
||||||
char *zCopy;
|
char *zCopy;
|
||||||
char *zEnd; /* Pointer to nul-term of zCopy */
|
char *zEnd; /* Pointer to nul-term of zCopy */
|
||||||
sqlite3_tokenizer_module *m;
|
sqlite3_tokenizer_module *m;
|
||||||
|
@@ -1323,7 +1323,7 @@ int sqlite3Fts3MsrOvfl(
|
|||||||
if( !fts3SegReaderIsPending(pReader)
|
if( !fts3SegReaderIsPending(pReader)
|
||||||
&& !fts3SegReaderIsRootOnly(pReader)
|
&& !fts3SegReaderIsRootOnly(pReader)
|
||||||
){
|
){
|
||||||
int jj;
|
sqlite3_int64 jj;
|
||||||
for(jj=pReader->iStartBlock; jj<=pReader->iLeafEndBlock; jj++){
|
for(jj=pReader->iStartBlock; jj<=pReader->iLeafEndBlock; jj++){
|
||||||
int nBlob;
|
int nBlob;
|
||||||
rc = sqlite3Fts3ReadBlock(p, jj, 0, &nBlob, 0);
|
rc = sqlite3Fts3ReadBlock(p, jj, 0, &nBlob, 0);
|
||||||
|
@@ -1421,7 +1421,7 @@ static float cellArea(Rtree *pRtree, RtreeCell *p){
|
|||||||
float area = 1.0;
|
float area = 1.0;
|
||||||
int ii;
|
int ii;
|
||||||
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
|
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
|
||||||
area = area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]));
|
area = (float)(area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])));
|
||||||
}
|
}
|
||||||
return area;
|
return area;
|
||||||
}
|
}
|
||||||
@@ -1434,7 +1434,7 @@ static float cellMargin(Rtree *pRtree, RtreeCell *p){
|
|||||||
float margin = 0.0;
|
float margin = 0.0;
|
||||||
int ii;
|
int ii;
|
||||||
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
|
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
|
||||||
margin += (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]));
|
margin += (float)(DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]));
|
||||||
}
|
}
|
||||||
return margin;
|
return margin;
|
||||||
}
|
}
|
||||||
@@ -1519,7 +1519,7 @@ static float cellOverlap(
|
|||||||
o = 0.0;
|
o = 0.0;
|
||||||
break;
|
break;
|
||||||
}else{
|
}else{
|
||||||
o = o * (x2-x1);
|
o = o * (float)(x2-x1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
overlap += o;
|
overlap += o;
|
||||||
@@ -1538,12 +1538,12 @@ static float cellOverlapEnlargement(
|
|||||||
int nCell,
|
int nCell,
|
||||||
int iExclude
|
int iExclude
|
||||||
){
|
){
|
||||||
float before;
|
double before;
|
||||||
float after;
|
double after;
|
||||||
before = cellOverlap(pRtree, p, aCell, nCell, iExclude);
|
before = cellOverlap(pRtree, p, aCell, nCell, iExclude);
|
||||||
cellUnion(pRtree, p, pInsert);
|
cellUnion(pRtree, p, pInsert);
|
||||||
after = cellOverlap(pRtree, p, aCell, nCell, iExclude);
|
after = cellOverlap(pRtree, p, aCell, nCell, iExclude);
|
||||||
return after-before;
|
return (float)(after-before);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -1565,11 +1565,11 @@ static int ChooseLeaf(
|
|||||||
|
|
||||||
for(ii=0; rc==SQLITE_OK && ii<(pRtree->iDepth-iHeight); ii++){
|
for(ii=0; rc==SQLITE_OK && ii<(pRtree->iDepth-iHeight); ii++){
|
||||||
int iCell;
|
int iCell;
|
||||||
sqlite3_int64 iBest;
|
sqlite3_int64 iBest = 0;
|
||||||
|
|
||||||
float fMinGrowth;
|
float fMinGrowth = 0.0;
|
||||||
float fMinArea;
|
float fMinArea = 0.0;
|
||||||
float fMinOverlap;
|
float fMinOverlap = 0.0;
|
||||||
|
|
||||||
int nCell = NCELL(pNode);
|
int nCell = NCELL(pNode);
|
||||||
RtreeCell cell;
|
RtreeCell cell;
|
||||||
@@ -1999,9 +1999,9 @@ static int splitNodeStartree(
|
|||||||
int *aSpare;
|
int *aSpare;
|
||||||
int ii;
|
int ii;
|
||||||
|
|
||||||
int iBestDim;
|
int iBestDim = 0;
|
||||||
int iBestSplit;
|
int iBestSplit = 0;
|
||||||
float fBestMargin;
|
float fBestMargin = 0.0;
|
||||||
|
|
||||||
int nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int));
|
int nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int));
|
||||||
|
|
||||||
@@ -2023,9 +2023,9 @@ static int splitNodeStartree(
|
|||||||
|
|
||||||
for(ii=0; ii<pRtree->nDim; ii++){
|
for(ii=0; ii<pRtree->nDim; ii++){
|
||||||
float margin = 0.0;
|
float margin = 0.0;
|
||||||
float fBestOverlap;
|
float fBestOverlap = 0.0;
|
||||||
float fBestArea;
|
float fBestArea = 0.0;
|
||||||
int iBestLeft;
|
int iBestLeft = 0;
|
||||||
int nLeft;
|
int nLeft;
|
||||||
|
|
||||||
for(
|
for(
|
||||||
@@ -2340,7 +2340,7 @@ static int deleteCell(Rtree *, RtreeNode *, int, int);
|
|||||||
static int removeNode(Rtree *pRtree, RtreeNode *pNode, int iHeight){
|
static int removeNode(Rtree *pRtree, RtreeNode *pNode, int iHeight){
|
||||||
int rc;
|
int rc;
|
||||||
int rc2;
|
int rc2;
|
||||||
RtreeNode *pParent;
|
RtreeNode *pParent = 0;
|
||||||
int iCell;
|
int iCell;
|
||||||
|
|
||||||
assert( pNode->nRef==1 );
|
assert( pNode->nRef==1 );
|
||||||
@@ -2488,19 +2488,19 @@ static int Reinsert(
|
|||||||
}
|
}
|
||||||
aOrder[ii] = ii;
|
aOrder[ii] = ii;
|
||||||
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
||||||
aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2]);
|
aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2]);
|
||||||
aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2+1]);
|
aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2+1]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
||||||
aCenterCoord[iDim] = aCenterCoord[iDim]/((float)nCell*2.0);
|
aCenterCoord[iDim] = (float)(aCenterCoord[iDim]/((float)nCell*2.0));
|
||||||
}
|
}
|
||||||
|
|
||||||
for(ii=0; ii<nCell; ii++){
|
for(ii=0; ii<nCell; ii++){
|
||||||
aDistance[ii] = 0.0;
|
aDistance[ii] = 0.0;
|
||||||
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
for(iDim=0; iDim<pRtree->nDim; iDim++){
|
||||||
float coord = DCOORD(aCell[ii].aCoord[iDim*2+1]) -
|
float coord = (float)(DCOORD(aCell[ii].aCoord[iDim*2+1]) -
|
||||||
DCOORD(aCell[ii].aCoord[iDim*2]);
|
DCOORD(aCell[ii].aCoord[iDim*2]));
|
||||||
aDistance[ii] += (coord-aCenterCoord[iDim])*(coord-aCenterCoord[iDim]);
|
aDistance[ii] += (coord-aCenterCoord[iDim])*(coord-aCenterCoord[iDim]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2599,10 +2599,10 @@ static int reinsertNodeContent(Rtree *pRtree, RtreeNode *pNode){
|
|||||||
/* Find a node to store this cell in. pNode->iNode currently contains
|
/* Find a node to store this cell in. pNode->iNode currently contains
|
||||||
** the height of the sub-tree headed by the cell.
|
** the height of the sub-tree headed by the cell.
|
||||||
*/
|
*/
|
||||||
rc = ChooseLeaf(pRtree, &cell, pNode->iNode, &pInsert);
|
rc = ChooseLeaf(pRtree, &cell, (int)pNode->iNode, &pInsert);
|
||||||
if( rc==SQLITE_OK ){
|
if( rc==SQLITE_OK ){
|
||||||
int rc2;
|
int rc2;
|
||||||
rc = rtreeInsertCell(pRtree, pInsert, &cell, pNode->iNode);
|
rc = rtreeInsertCell(pRtree, pInsert, &cell, (int)pNode->iNode);
|
||||||
rc2 = nodeRelease(pRtree, pInsert);
|
rc2 = nodeRelease(pRtree, pInsert);
|
||||||
if( rc==SQLITE_OK ){
|
if( rc==SQLITE_OK ){
|
||||||
rc = rc2;
|
rc = rc2;
|
||||||
@@ -2991,7 +2991,7 @@ static int getNodeSize(
|
|||||||
int rc;
|
int rc;
|
||||||
char *zSql;
|
char *zSql;
|
||||||
if( isCreate ){
|
if( isCreate ){
|
||||||
int iPageSize;
|
int iPageSize = 0;
|
||||||
zSql = sqlite3_mprintf("PRAGMA %Q.page_size", pRtree->zDb);
|
zSql = sqlite3_mprintf("PRAGMA %Q.page_size", pRtree->zDb);
|
||||||
rc = getIntFromStmt(db, zSql, &iPageSize);
|
rc = getIntFromStmt(db, zSql, &iPageSize);
|
||||||
if( rc==SQLITE_OK ){
|
if( rc==SQLITE_OK ){
|
||||||
|
72
manifest
72
manifest
@@ -1,9 +1,9 @@
|
|||||||
C (no\scomment)
|
C Merge\sthe\slatest\strunk\schanges\sinto\sthe\ssessions\sbranch.
|
||||||
D 2011-06-20T11:17:11.686
|
D 2011-06-21T01:29:16.319
|
||||||
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
|
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
|
||||||
F Makefile.in c1d7a7f4fd8da6b1815032efca950e3d5125407e
|
F Makefile.in c1d7a7f4fd8da6b1815032efca950e3d5125407e
|
||||||
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
|
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
|
||||||
F Makefile.msc ce73810c83d4bd202deb59d547a5df4a5cfef7c9
|
F Makefile.msc c942f2ceb9385d6c75b01ee3d38d8a189fb76e8c
|
||||||
F Makefile.vxworks c85ec1d8597fe2f7bc225af12ac1666e21379151
|
F Makefile.vxworks c85ec1d8597fe2f7bc225af12ac1666e21379151
|
||||||
F README cd04a36fbc7ea56932a4052d7d0b7f09f27c33d6
|
F README cd04a36fbc7ea56932a4052d7d0b7f09f27c33d6
|
||||||
F VERSION 3fcdd7fbe3eb282df3978fe77288544543767961
|
F VERSION 3fcdd7fbe3eb282df3978fe77288544543767961
|
||||||
@@ -21,10 +21,10 @@ F art/sqlite370.ico af56c1d00fee7cd4753e8631ed60703ed0fc6e90
|
|||||||
F art/sqlite370.jpg d512473dae7e378a67e28ff96a34da7cb331def2
|
F art/sqlite370.jpg d512473dae7e378a67e28ff96a34da7cb331def2
|
||||||
F art/src_logo.gif 9341ef09f0e53cd44c0c9b6fc3c16f7f3d6c2ad9
|
F art/src_logo.gif 9341ef09f0e53cd44c0c9b6fc3c16f7f3d6c2ad9
|
||||||
F config.guess 226d9a188c6196f3033ffc651cbc9dcee1a42977
|
F config.guess 226d9a188c6196f3033ffc651cbc9dcee1a42977
|
||||||
F config.h.in 868fdb48c028421a203470e15c69ada15b9ba673
|
F config.h.in 405a958bdb3af382a809dccb08a44694923ddd61
|
||||||
F config.sub 9ebe4c3b3dab6431ece34f16828b594fb420da55
|
F config.sub 9ebe4c3b3dab6431ece34f16828b594fb420da55
|
||||||
F configure 1c31f231ba59b71ff81dbf5c7c7594fdc83803d5 x
|
F configure f9e97ee7cdc9848e2f3f5ef015fdf861f46fb1bf x
|
||||||
F configure.ac 87a3c71bbe9c925381c154413eea7f3cdc397244
|
F configure.ac 298a759c086e72c013da459c2aec02a104f4224f
|
||||||
F contrib/sqlitecon.tcl 210a913ad63f9f991070821e599d600bd913e0ad
|
F contrib/sqlitecon.tcl 210a913ad63f9f991070821e599d600bd913e0ad
|
||||||
F doc/lemon.html f0f682f50210928c07e562621c3b7e8ab912a538
|
F doc/lemon.html f0f682f50210928c07e562621c3b7e8ab912a538
|
||||||
F doc/pager-invariants.txt 870107036470d7c419e93768676fae2f8749cf9e
|
F doc/pager-invariants.txt 870107036470d7c419e93768676fae2f8749cf9e
|
||||||
@@ -62,29 +62,29 @@ F ext/fts2/mkfts2amal.tcl 974d5d438cb3f7c4a652639262f82418c1e4cff0
|
|||||||
F ext/fts3/README.syntax a19711dc5458c20734b8e485e75fb1981ec2427a
|
F ext/fts3/README.syntax a19711dc5458c20734b8e485e75fb1981ec2427a
|
||||||
F ext/fts3/README.tokenizers 998756696647400de63d5ba60e9655036cb966e9
|
F ext/fts3/README.tokenizers 998756696647400de63d5ba60e9655036cb966e9
|
||||||
F ext/fts3/README.txt 8c18f41574404623b76917b9da66fcb0ab38328d
|
F ext/fts3/README.txt 8c18f41574404623b76917b9da66fcb0ab38328d
|
||||||
F ext/fts3/fts3.c f919a7966426e539b3f39f696bc94269e3726033
|
F ext/fts3/fts3.c 1c8a45dfd6836e7dea0307008079793ac0fc3b68
|
||||||
F ext/fts3/fts3.h 3a10a0af180d502cecc50df77b1b22df142817fe
|
F ext/fts3/fts3.h 3a10a0af180d502cecc50df77b1b22df142817fe
|
||||||
F ext/fts3/fts3Int.h 8ece4390eb44e7179bb05c59d40f447663f5c077
|
F ext/fts3/fts3Int.h fa493ccbad78a2c99ad1c984f651c0c202e68536
|
||||||
F ext/fts3/fts3_aux.c 0ebfa7b86cf8ff6a0861605fcc63b83ec1b70691
|
F ext/fts3/fts3_aux.c 0ebfa7b86cf8ff6a0861605fcc63b83ec1b70691
|
||||||
F ext/fts3/fts3_expr.c 23791de01b3a5d313d76e02befd2601d4096bc2b
|
F ext/fts3/fts3_expr.c 23791de01b3a5d313d76e02befd2601d4096bc2b
|
||||||
F ext/fts3/fts3_hash.c aad95afa01cf2a5ffaa448e4b0ab043880cd1efb
|
F ext/fts3/fts3_hash.c aad95afa01cf2a5ffaa448e4b0ab043880cd1efb
|
||||||
F ext/fts3/fts3_hash.h 8331fb2206c609f9fc4c4735b9ab5ad6137c88ec
|
F ext/fts3/fts3_hash.h 8331fb2206c609f9fc4c4735b9ab5ad6137c88ec
|
||||||
F ext/fts3/fts3_icu.c 6c8f395cdf9e1e3afa7fadb7e523dbbf381c6dfa
|
F ext/fts3/fts3_icu.c 6c8f395cdf9e1e3afa7fadb7e523dbbf381c6dfa
|
||||||
F ext/fts3/fts3_porter.c 8d946908f4812c005d3d33fcbe78418b1f4eb70c
|
F ext/fts3/fts3_porter.c 8d946908f4812c005d3d33fcbe78418b1f4eb70c
|
||||||
F ext/fts3/fts3_snippet.c a44b38a07d39701ab6d20d7d89fcafe193bf3680
|
F ext/fts3/fts3_snippet.c 58b2ba2b934c1e2a2f6ac857d7f3c7e1a14b4532
|
||||||
F ext/fts3/fts3_term.c 51e384269edcc015e8b555fdad2338f053388975
|
F ext/fts3/fts3_term.c a5457992723455a58804cb75c8cbd8978db5c2ef
|
||||||
F ext/fts3/fts3_test.c b66f6c17f3430b3078d0bc5a77ecb124e5ffc901
|
F ext/fts3/fts3_test.c c0aae3219df989d3e827d07846097adf8cb09945
|
||||||
F ext/fts3/fts3_tokenizer.c 90ba6cdd8bb1b3686ab7a3d72333131e13c8fdb2
|
F ext/fts3/fts3_tokenizer.c 6089986ebcfc19d4b7aabd2b92773368efa4354f
|
||||||
F ext/fts3/fts3_tokenizer.h 13ffd9fcb397fec32a05ef5cd9e0fa659bf3dbd3
|
F ext/fts3/fts3_tokenizer.h 13ffd9fcb397fec32a05ef5cd9e0fa659bf3dbd3
|
||||||
F ext/fts3/fts3_tokenizer1.c 0dde8f307b8045565cf63797ba9acfaff1c50c68
|
F ext/fts3/fts3_tokenizer1.c 0dde8f307b8045565cf63797ba9acfaff1c50c68
|
||||||
F ext/fts3/fts3_write.c 5774a7ee9632355ebf1ec4b7a5071fc9ab9eb956
|
F ext/fts3/fts3_write.c 194829c8fd024a448fc899e5ff02a8ed06595529
|
||||||
F ext/fts3/fts3speed.tcl b54caf6a18d38174f1a6e84219950d85e98bb1e9
|
F ext/fts3/fts3speed.tcl b54caf6a18d38174f1a6e84219950d85e98bb1e9
|
||||||
F ext/fts3/mkfts3amal.tcl 252ecb7fe6467854f2aa237bf2c390b74e71f100
|
F ext/fts3/mkfts3amal.tcl 252ecb7fe6467854f2aa237bf2c390b74e71f100
|
||||||
F ext/icu/README.txt bf8461d8cdc6b8f514c080e4e10dc3b2bbdfefa9
|
F ext/icu/README.txt bf8461d8cdc6b8f514c080e4e10dc3b2bbdfefa9
|
||||||
F ext/icu/icu.c eb9ae1d79046bd7871aa97ee6da51eb770134b5a
|
F ext/icu/icu.c eb9ae1d79046bd7871aa97ee6da51eb770134b5a
|
||||||
F ext/icu/sqliteicu.h 728867a802baa5a96de7495e9689a8e01715ef37
|
F ext/icu/sqliteicu.h 728867a802baa5a96de7495e9689a8e01715ef37
|
||||||
F ext/rtree/README 6315c0d73ebf0ec40dedb5aa0e942bc8b54e3761
|
F ext/rtree/README 6315c0d73ebf0ec40dedb5aa0e942bc8b54e3761
|
||||||
F ext/rtree/rtree.c 4b8438444927191b55de18e00df43b2e02aacbda
|
F ext/rtree/rtree.c b431c54d1ed05f04f2987e8a4fbb931acb40c312
|
||||||
F ext/rtree/rtree.h 834dbcb82dc85b2481cde6a07cdadfddc99e9b9e
|
F ext/rtree/rtree.h 834dbcb82dc85b2481cde6a07cdadfddc99e9b9e
|
||||||
F ext/rtree/rtree1.test 28e1b8da4da98093ce3210187434dd760a8d89d8
|
F ext/rtree/rtree1.test 28e1b8da4da98093ce3210187434dd760a8d89d8
|
||||||
F ext/rtree/rtree2.test acbb3a4ce0f4fbc2c304d2b4b784cfa161856bba
|
F ext/rtree/rtree2.test acbb3a4ce0f4fbc2c304d2b4b784cfa161856bba
|
||||||
@@ -175,8 +175,8 @@ F src/os.c 22ac61d06e72a0dac900400147333b07b13d8e1d
|
|||||||
F src/os.h 9dbed8c2b9c1f2f2ebabc09e49829d4777c26bf9
|
F src/os.h 9dbed8c2b9c1f2f2ebabc09e49829d4777c26bf9
|
||||||
F src/os_common.h a8f95b81eca8a1ab8593d23e94f8a35f35d4078f
|
F src/os_common.h a8f95b81eca8a1ab8593d23e94f8a35f35d4078f
|
||||||
F src/os_os2.c 4a75888ba3dfc820ad5e8177025972d74d7f2440
|
F src/os_os2.c 4a75888ba3dfc820ad5e8177025972d74d7f2440
|
||||||
F src/os_unix.c fd4e9588ff0ce09720721ce739ab2682202875ae
|
F src/os_unix.c 07acbb3e074e52b48a4248c06f66c9a91db1a0ce
|
||||||
F src/os_win.c 218b899469e570d46eb8147c2383075f7c026230
|
F src/os_win.c eafcd6b91cf204a7ef29ac1ef2a1b7132e132e58
|
||||||
F src/pager.c 120550e7ef01dafaa2cbb4a0528c0d87c8f12b41
|
F src/pager.c 120550e7ef01dafaa2cbb4a0528c0d87c8f12b41
|
||||||
F src/pager.h 3f8c783de1d4706b40b1ac15b64f5f896bcc78d1
|
F src/pager.h 3f8c783de1d4706b40b1ac15b64f5f896bcc78d1
|
||||||
F src/parse.y 12b7ebd61ea54f0e1b1083ff69cc2c8ce9353d58
|
F src/parse.y 12b7ebd61ea54f0e1b1083ff69cc2c8ce9353d58
|
||||||
@@ -191,13 +191,13 @@ F src/resolve.c 1c0f32b64f8e3f555fe1f732f9d6f501a7f05706
|
|||||||
F src/rowset.c 69afa95a97c524ba6faf3805e717b5b7ae85a697
|
F src/rowset.c 69afa95a97c524ba6faf3805e717b5b7ae85a697
|
||||||
F src/select.c d9d440809025a58547e39f4f268c2a296bfb56ff
|
F src/select.c d9d440809025a58547e39f4f268c2a296bfb56ff
|
||||||
F src/shell.c 0e0173b3e79d956368013e759f084caa7995ecb1
|
F src/shell.c 0e0173b3e79d956368013e759f084caa7995ecb1
|
||||||
F src/sqlite.h.in 1daf26cc593fa78dd041af564c708869b1f12df3
|
F src/sqlite.h.in 6bff7c59ae3cec01e628800b79ae87a2897c576c
|
||||||
F src/sqlite3ext.h c90bd5507099f62043832d73f6425d8d5c5da754
|
F src/sqlite3ext.h c90bd5507099f62043832d73f6425d8d5c5da754
|
||||||
F src/sqliteInt.h 928caa40080d47e8f92e1edee83f6249d03c5862
|
F src/sqliteInt.h 928caa40080d47e8f92e1edee83f6249d03c5862
|
||||||
F src/sqliteLimit.h 164b0e6749d31e0daa1a4589a169d31c0dec7b3d
|
F src/sqliteLimit.h 164b0e6749d31e0daa1a4589a169d31c0dec7b3d
|
||||||
F src/status.c 7ac64842c86cec2fc1a1d0e5c16d3beb8ad332bf
|
F src/status.c 7ac64842c86cec2fc1a1d0e5c16d3beb8ad332bf
|
||||||
F src/table.c 2cd62736f845d82200acfa1287e33feb3c15d62e
|
F src/table.c 2cd62736f845d82200acfa1287e33feb3c15d62e
|
||||||
F src/tclsqlite.c 2c9ac84e46f9753e05dff1f1bfc745a390ebeb64
|
F src/tclsqlite.c 6a34149c9ff4a6f998a4cb8336d4481670b576b6
|
||||||
F src/test1.c efca486a25fb894988e7a82e84579a4e57388a02
|
F src/test1.c efca486a25fb894988e7a82e84579a4e57388a02
|
||||||
F src/test2.c 80d323d11e909cf0eb1b6fbb4ac22276483bcf31
|
F src/test2.c 80d323d11e909cf0eb1b6fbb4ac22276483bcf31
|
||||||
F src/test3.c 124ff9735fb6bb7d41de180d6bac90e7b1509432
|
F src/test3.c 124ff9735fb6bb7d41de180d6bac90e7b1509432
|
||||||
@@ -211,7 +211,7 @@ F src/test_async.c 0612a752896fad42d55c3999a5122af10dcf22ad
|
|||||||
F src/test_autoext.c 30e7bd98ab6d70a62bb9ba572e4c7df347fe645e
|
F src/test_autoext.c 30e7bd98ab6d70a62bb9ba572e4c7df347fe645e
|
||||||
F src/test_backup.c c129c91127e9b46e335715ae2e75756e25ba27de
|
F src/test_backup.c c129c91127e9b46e335715ae2e75756e25ba27de
|
||||||
F src/test_btree.c 47cd771250f09cdc6e12dda5bc71bc0b3abc96e2
|
F src/test_btree.c 47cd771250f09cdc6e12dda5bc71bc0b3abc96e2
|
||||||
F src/test_config.c 2794d55f27c7faa6c8203b15e634e7103953ddcc
|
F src/test_config.c 470765ec36636d2c598766342b58e4c841e24512
|
||||||
F src/test_demovfs.c 20a4975127993f4959890016ae9ce5535a880094
|
F src/test_demovfs.c 20a4975127993f4959890016ae9ce5535a880094
|
||||||
F src/test_devsym.c e7498904e72ba7491d142d5c83b476c4e76993bc
|
F src/test_devsym.c e7498904e72ba7491d142d5c83b476c4e76993bc
|
||||||
F src/test_func.c cbdec5cededa0761daedde5baf06004a9bf416b5
|
F src/test_func.c cbdec5cededa0761daedde5baf06004a9bf416b5
|
||||||
@@ -237,7 +237,7 @@ F src/test_stat.c f682704b5d1ba8e1d4e7e882a6d7922e2dcf066c
|
|||||||
F src/test_superlock.c 2b97936ca127d13962c3605dbc9a4ef269c424cd
|
F src/test_superlock.c 2b97936ca127d13962c3605dbc9a4ef269c424cd
|
||||||
F src/test_syscall.c 162c4ec0137a549c009bb9ecab550527743cfc5d
|
F src/test_syscall.c 162c4ec0137a549c009bb9ecab550527743cfc5d
|
||||||
F src/test_tclvar.c f4dc67d5f780707210d6bb0eb6016a431c04c7fa
|
F src/test_tclvar.c f4dc67d5f780707210d6bb0eb6016a431c04c7fa
|
||||||
F src/test_thread.c 361ae0a0f1cbf5a28ad0388a258b104017a370c0
|
F src/test_thread.c fe9a7803fc1d69cccb60f016f28c1cedf2d9fcfa
|
||||||
F src/test_vfs.c e7855568dfa1e0ba73668d273b65605d9f8b77e8
|
F src/test_vfs.c e7855568dfa1e0ba73668d273b65605d9f8b77e8
|
||||||
F src/test_vfstrace.c 0b884e06094a746da729119a2cabdc7aa790063d
|
F src/test_vfstrace.c 0b884e06094a746da729119a2cabdc7aa790063d
|
||||||
F src/test_wholenumber.c 6129adfbe7c7444f2e60cc785927f3aa74e12290
|
F src/test_wholenumber.c 6129adfbe7c7444f2e60cc785927f3aa74e12290
|
||||||
@@ -248,7 +248,7 @@ F src/update.c a81bda229f8c3b698f8dcf8e69485c97e1347102
|
|||||||
F src/utf.c c53eb7404b3eb5c1cbb5655c6a7a0e0ce6bd50f0
|
F src/utf.c c53eb7404b3eb5c1cbb5655c6a7a0e0ce6bd50f0
|
||||||
F src/util.c 0f33bbbdfcc4a2d8cf20c3b2a16ffc3b57c58a70
|
F src/util.c 0f33bbbdfcc4a2d8cf20c3b2a16ffc3b57c58a70
|
||||||
F src/vacuum.c 05513dca036a1e7848fe18d5ed1265ac0b32365e
|
F src/vacuum.c 05513dca036a1e7848fe18d5ed1265ac0b32365e
|
||||||
F src/vdbe.c af4d8ba06efb768f405d189d4b992c81ae14d711
|
F src/vdbe.c df52db6162fd94767b76bb4e9a7cb9207e83086f
|
||||||
F src/vdbe.h 322af148cceef120bb1ec9cff7f122e76abf94da
|
F src/vdbe.h 322af148cceef120bb1ec9cff7f122e76abf94da
|
||||||
F src/vdbeInt.h 3de6588b36c833969aebab202e1766d586c37ec2
|
F src/vdbeInt.h 3de6588b36c833969aebab202e1766d586c37ec2
|
||||||
F src/vdbeapi.c 3f6e988bd19391be1aa49ffd1f259654dcc8d975
|
F src/vdbeapi.c 3f6e988bd19391be1aa49ffd1f259654dcc8d975
|
||||||
@@ -380,24 +380,24 @@ F test/descidx3.test fe720e8b37d59f4cef808b0bf4e1b391c2e56b6f
|
|||||||
F test/diskfull.test 0cede7ef9d8f415d9d3944005c76be7589bb5ebb
|
F test/diskfull.test 0cede7ef9d8f415d9d3944005c76be7589bb5ebb
|
||||||
F test/distinctagg.test 1a6ef9c87a58669438fc771450d7a72577417376
|
F test/distinctagg.test 1a6ef9c87a58669438fc771450d7a72577417376
|
||||||
F test/e_createtable.test 4771686a586b6ae414f927c389b2c101cc05c028
|
F test/e_createtable.test 4771686a586b6ae414f927c389b2c101cc05c028
|
||||||
F test/e_delete.test 55d868b647acc091c261a10b9b0cb0ab660a6acb
|
F test/e_delete.test e2ae0d3fce5efd70fef99025e932afffc5616fab
|
||||||
F test/e_droptrigger.test ddd4b28ed8a3d81bd5153fa0ab7559529a2ca03a
|
F test/e_droptrigger.test ddd4b28ed8a3d81bd5153fa0ab7559529a2ca03a
|
||||||
F test/e_dropview.test b347bab30fc8de67b131594b3cd6f3d3bdaa753d
|
F test/e_dropview.test b347bab30fc8de67b131594b3cd6f3d3bdaa753d
|
||||||
F test/e_expr.test 9e8b9790803df4de23c2d68d566959934a6179d4
|
F test/e_expr.test 71b55f90c9336ecec5a99641679036931260c754
|
||||||
F test/e_fkey.test 38039b840ab19331000b0f0eb1d82baa7208a67a
|
F test/e_fkey.test 38039b840ab19331000b0f0eb1d82baa7208a67a
|
||||||
F test/e_fts3.test 75bb0aee26384ef586165e21018a17f7cd843469
|
F test/e_fts3.test 75bb0aee26384ef586165e21018a17f7cd843469
|
||||||
F test/e_insert.test 7390c2da39f16a134dc9a439144768c727757d2c
|
F test/e_insert.test 76d4bb5da9b28014d515d91ffe29a79a1e99f2bc
|
||||||
F test/e_reindex.test a064f0878b8f848fbca38f1f61f82f15a3000c64
|
F test/e_reindex.test a064f0878b8f848fbca38f1f61f82f15a3000c64
|
||||||
F test/e_resolve.test dcce9308fb13b934ce29591105d031d3e14fbba6
|
F test/e_resolve.test dcce9308fb13b934ce29591105d031d3e14fbba6
|
||||||
F test/e_select.test bf385ae3aa0f014c4933ae66fd3e1302138493eb
|
F test/e_select.test 7ac53674e822d4d77bbb4a9a4aaefa5fdc9e493f
|
||||||
F test/e_select2.test 5c3d3da19c7b3e90ae444579db2b70098599ab92
|
F test/e_select2.test 5c3d3da19c7b3e90ae444579db2b70098599ab92
|
||||||
F test/e_update.test 963d6876064e65f318d1c93aaed36a02b9b389bf
|
F test/e_update.test b926341a65955d69a6375c9eb4fd82e7089bc83a
|
||||||
F test/e_uri.test b6da43a10f44d9aa0aff5ffa3c2f3de668361255
|
F test/e_uri.test 8b943bc63cd1abb037430214cdb618422e6bf7d6
|
||||||
F test/e_vacuum.test 6c09c2af7f2f140518f371c5342100118f779dcf
|
F test/e_vacuum.test 6c09c2af7f2f140518f371c5342100118f779dcf
|
||||||
F test/enc.test e54531cd6bf941ee6760be041dff19a104c7acea
|
F test/enc.test e54531cd6bf941ee6760be041dff19a104c7acea
|
||||||
F test/enc2.test 6d91a5286f59add0cfcbb2d0da913b76f2242398
|
F test/enc2.test 6d91a5286f59add0cfcbb2d0da913b76f2242398
|
||||||
F test/enc3.test 5c550d59ff31dccdba5d1a02ae11c7047d77c041
|
F test/enc3.test 5c550d59ff31dccdba5d1a02ae11c7047d77c041
|
||||||
F test/enc4.test 4b575ef09e0eff896e73bd24076f96c2aa6a42de
|
F test/enc4.test b145fa25feb56ea1d51a5bc43ca268c0cf691a67
|
||||||
F test/eqp.test f14fadd76da53405e9885e2431cacf7191d83cdb
|
F test/eqp.test f14fadd76da53405e9885e2431cacf7191d83cdb
|
||||||
F test/eval.test bc269c365ba877554948441e91ad5373f9f91be3
|
F test/eval.test bc269c365ba877554948441e91ad5373f9f91be3
|
||||||
F test/exclusive.test 53e1841b422e554cecf0160f937c473d6d0e3062
|
F test/exclusive.test 53e1841b422e554cecf0160f937c473d6d0e3062
|
||||||
@@ -492,7 +492,7 @@ F test/fts3rnd.test 1320d8826a845e38a96e769562bf83d7a92a15d0
|
|||||||
F test/fts3shared.test 8bb266521d7c5495c0ae522bb4d376ad5387d4a2
|
F test/fts3shared.test 8bb266521d7c5495c0ae522bb4d376ad5387d4a2
|
||||||
F test/fts3snippet.test a12f22a3ba4dd59751a57c79b031d07ab5f51ddd
|
F test/fts3snippet.test a12f22a3ba4dd59751a57c79b031d07ab5f51ddd
|
||||||
F test/fts3sort.test 63d52c1812904b751f9e1ff487472e44833f5402
|
F test/fts3sort.test 63d52c1812904b751f9e1ff487472e44833f5402
|
||||||
F test/fts4aa.test eadf85621c0a113d4c7ad3ccbf8441130e007b8f
|
F test/fts4aa.test b99ad4d9a43a00efd096ef4d0b082de58d848d41
|
||||||
F test/func.test 6c5ce11e3a0021ca3c0649234e2d4454c89110ca
|
F test/func.test 6c5ce11e3a0021ca3c0649234e2d4454c89110ca
|
||||||
F test/func2.test 772d66227e4e6684b86053302e2d74a2500e1e0f
|
F test/func2.test 772d66227e4e6684b86053302e2d74a2500e1e0f
|
||||||
F test/func3.test 7ba2ca5a1e9bca900ba2c230cf04bd67184bc1bc
|
F test/func3.test 7ba2ca5a1e9bca900ba2c230cf04bd67184bc1bc
|
||||||
@@ -706,7 +706,7 @@ F test/tclsqlite.test 1ce9b6340d6d412420634e129a2e3722c651056a
|
|||||||
F test/tempdb.test 19d0f66e2e3eeffd68661a11c83ba5e6ace9128c
|
F test/tempdb.test 19d0f66e2e3eeffd68661a11c83ba5e6ace9128c
|
||||||
F test/temptable.test f42121a0d29a62f00f93274464164177ab1cc24a
|
F test/temptable.test f42121a0d29a62f00f93274464164177ab1cc24a
|
||||||
F test/temptrigger.test b0273db072ce5f37cf19140ceb1f0d524bbe9f05
|
F test/temptrigger.test b0273db072ce5f37cf19140ceb1f0d524bbe9f05
|
||||||
F test/tester.tcl 174f2bc00ddacc6c7666a15d3dbac9669dfc2373
|
F test/tester.tcl 7b91ddd9b2513024b4f95ac3c0151b2dab8433e0
|
||||||
F test/thread001.test a3e6a7254d1cb057836cb3145b60c10bf5b7e60f
|
F test/thread001.test a3e6a7254d1cb057836cb3145b60c10bf5b7e60f
|
||||||
F test/thread002.test afd20095e6e845b405df4f2c920cb93301ca69db
|
F test/thread002.test afd20095e6e845b405df4f2c920cb93301ca69db
|
||||||
F test/thread003.test b824d4f52b870ae39fc5bae4d8070eca73085dca
|
F test/thread003.test b824d4f52b870ae39fc5bae4d8070eca73085dca
|
||||||
@@ -925,12 +925,12 @@ F tool/fragck.tcl 5265a95126abcf6ab357f7efa544787e5963f439
|
|||||||
F tool/genfkey.README cf68fddd4643bbe3ff8e31b8b6d8b0a1b85e20f4
|
F tool/genfkey.README cf68fddd4643bbe3ff8e31b8b6d8b0a1b85e20f4
|
||||||
F tool/genfkey.test 4196a8928b78f51d54ef58e99e99401ab2f0a7e5
|
F tool/genfkey.test 4196a8928b78f51d54ef58e99e99401ab2f0a7e5
|
||||||
F tool/getlock.c f4c39b651370156cae979501a7b156bdba50e7ce
|
F tool/getlock.c f4c39b651370156cae979501a7b156bdba50e7ce
|
||||||
F tool/lemon.c 2f182cf58a44a29107ad0027e4e696c79cbb9ad6
|
F tool/lemon.c d51c68d405ff7f9bad99268ca3c20a198eb983ed
|
||||||
F tool/lempar.c 01ca97f87610d1dac6d8cd96ab109ab1130e76dc
|
F tool/lempar.c 01ca97f87610d1dac6d8cd96ab109ab1130e76dc
|
||||||
F tool/mkkeywordhash.c d2e6b4a5965e23afb80fbe74bb54648cd371f309
|
F tool/mkkeywordhash.c d2e6b4a5965e23afb80fbe74bb54648cd371f309
|
||||||
F tool/mkopts.tcl 66ac10d240cc6e86abd37dc908d50382f84ff46e
|
F tool/mkopts.tcl 66ac10d240cc6e86abd37dc908d50382f84ff46e
|
||||||
F tool/mkspeedsql.tcl a1a334d288f7adfe6e996f2e712becf076745c97
|
F tool/mkspeedsql.tcl a1a334d288f7adfe6e996f2e712becf076745c97
|
||||||
F tool/mksqlite3c.tcl b23027b185d3e7c7a1803c6f977f68bebd7bc3ec
|
F tool/mksqlite3c.tcl 1fa0ed9cfdc768bf5de7e65fda8d97a46dd2a7e6
|
||||||
F tool/mksqlite3h.tcl 78013ad79a5e492e5f764f3c7a8ef834255061f8
|
F tool/mksqlite3h.tcl 78013ad79a5e492e5f764f3c7a8ef834255061f8
|
||||||
F tool/mksqlite3internalh.tcl 7b43894e21bcb1bb39e11547ce7e38a063357e87
|
F tool/mksqlite3internalh.tcl 7b43894e21bcb1bb39e11547ce7e38a063357e87
|
||||||
F tool/omittest.tcl b1dd290c1596e0f31fd335160a74ec5dfea3df4a
|
F tool/omittest.tcl b1dd290c1596e0f31fd335160a74ec5dfea3df4a
|
||||||
@@ -957,7 +957,7 @@ F tool/split-sqlite3c.tcl d9be87f1c340285a3e081eb19b4a247981ed290c
|
|||||||
F tool/symbols.sh bc2a3709940d47c8ac8e0a1fdf17ec801f015a00
|
F tool/symbols.sh bc2a3709940d47c8ac8e0a1fdf17ec801f015a00
|
||||||
F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
|
F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
|
||||||
F tool/warnings.sh 347d974d143cf132f953b565fbc03026f19fcb4d
|
F tool/warnings.sh 347d974d143cf132f953b565fbc03026f19fcb4d
|
||||||
P 4c5e276c902e0b93cfc05bf2e1db966ecdac0ed0 e539d08a4dda073dc67dc39a104f89374d3bd8e9
|
P 699b884383f735fb9630d87d25dab61c97dc4485 e60eefc76fa5066720d76858f6cfca56365330ee
|
||||||
R f0476f177016b146d1b12f97f172f0c0
|
R e193f5c5190325b306fe583331238ae9
|
||||||
U dan
|
U drh
|
||||||
Z 9b9916cabe28f8e3dca16fc079f9fb31
|
Z 4fd98ca50300bc27a920f010541b7f13
|
||||||
|
@@ -1 +1 @@
|
|||||||
699b884383f735fb9630d87d25dab61c97dc4485
|
f3d148e0d10e16cd744ec88a2961fd617368c5ed
|
@@ -138,6 +138,10 @@
|
|||||||
# include <sys/mount.h>
|
# include <sys/mount.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_UTIME
|
||||||
|
# include <utime.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Allowed values of unixFile.fsFlags
|
** Allowed values of unixFile.fsFlags
|
||||||
*/
|
*/
|
||||||
@@ -1939,8 +1943,10 @@ static int dotlockLock(sqlite3_file *id, int eFileLock) {
|
|||||||
*/
|
*/
|
||||||
if( pFile->eFileLock > NO_LOCK ){
|
if( pFile->eFileLock > NO_LOCK ){
|
||||||
pFile->eFileLock = eFileLock;
|
pFile->eFileLock = eFileLock;
|
||||||
#if !OS_VXWORKS
|
|
||||||
/* Always update the timestamp on the old file */
|
/* Always update the timestamp on the old file */
|
||||||
|
#ifdef HAVE_UTIME
|
||||||
|
utime(zLockFile, NULL);
|
||||||
|
#else
|
||||||
utimes(zLockFile, NULL);
|
utimes(zLockFile, NULL);
|
||||||
#endif
|
#endif
|
||||||
return SQLITE_OK;
|
return SQLITE_OK;
|
||||||
|
@@ -878,7 +878,8 @@ static int winWrite(
|
|||||||
}
|
}
|
||||||
|
|
||||||
if( rc ){
|
if( rc ){
|
||||||
if( pFile->lastErrno==ERROR_HANDLE_DISK_FULL ){
|
if( ( pFile->lastErrno==ERROR_HANDLE_DISK_FULL )
|
||||||
|
|| ( pFile->lastErrno==ERROR_DISK_FULL )){
|
||||||
return SQLITE_FULL;
|
return SQLITE_FULL;
|
||||||
}
|
}
|
||||||
return winLogError(SQLITE_IOERR_WRITE, "winWrite", pFile->zPath);
|
return winLogError(SQLITE_IOERR_WRITE, "winWrite", pFile->zPath);
|
||||||
|
@@ -305,7 +305,7 @@ typedef int (*sqlite3_callback)(void*,int,char**, char**);
|
|||||||
** argument. ^If the callback function of the 3rd argument to
|
** argument. ^If the callback function of the 3rd argument to
|
||||||
** sqlite3_exec() is not NULL, then it is invoked for each result row
|
** sqlite3_exec() is not NULL, then it is invoked for each result row
|
||||||
** coming out of the evaluated SQL statements. ^The 4th argument to
|
** coming out of the evaluated SQL statements. ^The 4th argument to
|
||||||
** to sqlite3_exec() is relayed through to the 1st argument of each
|
** sqlite3_exec() is relayed through to the 1st argument of each
|
||||||
** callback invocation. ^If the callback pointer to sqlite3_exec()
|
** callback invocation. ^If the callback pointer to sqlite3_exec()
|
||||||
** is NULL, then no callback is ever invoked and result rows are
|
** is NULL, then no callback is ever invoked and result rows are
|
||||||
** ignored.
|
** ignored.
|
||||||
@@ -897,7 +897,7 @@ typedef struct sqlite3_mutex sqlite3_mutex;
|
|||||||
** method returns a Julian Day Number for the current date and time as
|
** method returns a Julian Day Number for the current date and time as
|
||||||
** a floating point value.
|
** a floating point value.
|
||||||
** ^The xCurrentTimeInt64() method returns, as an integer, the Julian
|
** ^The xCurrentTimeInt64() method returns, as an integer, the Julian
|
||||||
** Day Number multipled by 86400000 (the number of milliseconds in
|
** Day Number multiplied by 86400000 (the number of milliseconds in
|
||||||
** a 24-hour day).
|
** a 24-hour day).
|
||||||
** ^SQLite will use the xCurrentTimeInt64() method to get the current
|
** ^SQLite will use the xCurrentTimeInt64() method to get the current
|
||||||
** date and time if that method is available (if iVersion is 2 or
|
** date and time if that method is available (if iVersion is 2 or
|
||||||
@@ -1335,7 +1335,7 @@ struct sqlite3_mem_methods {
|
|||||||
**
|
**
|
||||||
** [[SQLITE_CONFIG_PAGECACHE]] <dt>SQLITE_CONFIG_PAGECACHE</dt>
|
** [[SQLITE_CONFIG_PAGECACHE]] <dt>SQLITE_CONFIG_PAGECACHE</dt>
|
||||||
** <dd> ^This option specifies a static memory buffer that SQLite can use for
|
** <dd> ^This option specifies a static memory buffer that SQLite can use for
|
||||||
** the database page cache with the default page cache implemenation.
|
** the database page cache with the default page cache implementation.
|
||||||
** This configuration should not be used if an application-define page
|
** This configuration should not be used if an application-define page
|
||||||
** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option.
|
** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option.
|
||||||
** There are three arguments to this option: A pointer to 8-byte aligned
|
** There are three arguments to this option: A pointer to 8-byte aligned
|
||||||
@@ -2433,12 +2433,12 @@ void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
|
|||||||
** ^If [URI filename] interpretation is enabled, and the filename argument
|
** ^If [URI filename] interpretation is enabled, and the filename argument
|
||||||
** begins with "file:", then the filename is interpreted as a URI. ^URI
|
** begins with "file:", then the filename is interpreted as a URI. ^URI
|
||||||
** filename interpretation is enabled if the [SQLITE_OPEN_URI] flag is
|
** filename interpretation is enabled if the [SQLITE_OPEN_URI] flag is
|
||||||
** is set in the fourth argument to sqlite3_open_v2(), or if it has
|
** set in the fourth argument to sqlite3_open_v2(), or if it has
|
||||||
** been enabled globally using the [SQLITE_CONFIG_URI] option with the
|
** been enabled globally using the [SQLITE_CONFIG_URI] option with the
|
||||||
** [sqlite3_config()] method or by the [SQLITE_USE_URI] compile-time option.
|
** [sqlite3_config()] method or by the [SQLITE_USE_URI] compile-time option.
|
||||||
** As of SQLite version 3.7.7, URI filename interpretation is turned off
|
** As of SQLite version 3.7.7, URI filename interpretation is turned off
|
||||||
** by default, but future releases of SQLite might enable URI filename
|
** by default, but future releases of SQLite might enable URI filename
|
||||||
** intepretation by default. See "[URI filenames]" for additional
|
** interpretation by default. See "[URI filenames]" for additional
|
||||||
** information.
|
** information.
|
||||||
**
|
**
|
||||||
** URI filenames are parsed according to RFC 3986. ^If the URI contains an
|
** URI filenames are parsed according to RFC 3986. ^If the URI contains an
|
||||||
@@ -3257,7 +3257,7 @@ const void *sqlite3_column_decltype16(sqlite3_stmt*,int);
|
|||||||
** ^[SQLITE_BUSY] means that the database engine was unable to acquire the
|
** ^[SQLITE_BUSY] means that the database engine was unable to acquire the
|
||||||
** database locks it needs to do its job. ^If the statement is a [COMMIT]
|
** database locks it needs to do its job. ^If the statement is a [COMMIT]
|
||||||
** or occurs outside of an explicit transaction, then you can retry the
|
** or occurs outside of an explicit transaction, then you can retry the
|
||||||
** statement. If the statement is not a [COMMIT] and occurs within a
|
** statement. If the statement is not a [COMMIT] and occurs within an
|
||||||
** explicit transaction then you should rollback the transaction before
|
** explicit transaction then you should rollback the transaction before
|
||||||
** continuing.
|
** continuing.
|
||||||
**
|
**
|
||||||
@@ -3536,7 +3536,7 @@ sqlite3_value *sqlite3_column_value(sqlite3_stmt*, int iCol);
|
|||||||
** CAPI3REF: Destroy A Prepared Statement Object
|
** CAPI3REF: Destroy A Prepared Statement Object
|
||||||
**
|
**
|
||||||
** ^The sqlite3_finalize() function is called to delete a [prepared statement].
|
** ^The sqlite3_finalize() function is called to delete a [prepared statement].
|
||||||
** ^If the most recent evaluation of the statement encountered no errors or
|
** ^If the most recent evaluation of the statement encountered no errors
|
||||||
** or if the statement is never been evaluated, then sqlite3_finalize() returns
|
** or if the statement is never been evaluated, then sqlite3_finalize() returns
|
||||||
** SQLITE_OK. ^If the most recent evaluation of statement S failed, then
|
** SQLITE_OK. ^If the most recent evaluation of statement S failed, then
|
||||||
** sqlite3_finalize(S) returns the appropriate [error code] or
|
** sqlite3_finalize(S) returns the appropriate [error code] or
|
||||||
@@ -5450,7 +5450,7 @@ struct sqlite3_mutex_methods {
|
|||||||
**
|
**
|
||||||
** ^If the argument to sqlite3_mutex_held() is a NULL pointer then
|
** ^If the argument to sqlite3_mutex_held() is a NULL pointer then
|
||||||
** the routine should return 1. This seems counter-intuitive since
|
** the routine should return 1. This seems counter-intuitive since
|
||||||
** clearly the mutex cannot be held if it does not exist. But the
|
** clearly the mutex cannot be held if it does not exist. But
|
||||||
** the reason the mutex does not exist is because the build is not
|
** the reason the mutex does not exist is because the build is not
|
||||||
** using mutexes. And we do not want the assert() containing the
|
** using mutexes. And we do not want the assert() containing the
|
||||||
** call to sqlite3_mutex_held() to fail, so a non-zero return is
|
** call to sqlite3_mutex_held() to fail, so a non-zero return is
|
||||||
@@ -5959,7 +5959,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
|
|||||||
** the page, or a NULL pointer.
|
** the page, or a NULL pointer.
|
||||||
** A "page", in this context, means a buffer of szPage bytes aligned at an
|
** A "page", in this context, means a buffer of szPage bytes aligned at an
|
||||||
** 8-byte boundary. The page to be fetched is determined by the key. ^The
|
** 8-byte boundary. The page to be fetched is determined by the key. ^The
|
||||||
** mimimum key value is 1. After it has been retrieved using xFetch, the page
|
** minimum key value is 1. After it has been retrieved using xFetch, the page
|
||||||
** is considered to be "pinned".
|
** is considered to be "pinned".
|
||||||
**
|
**
|
||||||
** If the requested page is already in the page cache, then the page cache
|
** If the requested page is already in the page cache, then the page cache
|
||||||
|
@@ -805,7 +805,7 @@ static void tclSqlFunc(sqlite3_context *context, int argc, sqlite3_value**argv){
|
|||||||
case SQLITE_INTEGER: {
|
case SQLITE_INTEGER: {
|
||||||
sqlite_int64 v = sqlite3_value_int64(pIn);
|
sqlite_int64 v = sqlite3_value_int64(pIn);
|
||||||
if( v>=-2147483647 && v<=2147483647 ){
|
if( v>=-2147483647 && v<=2147483647 ){
|
||||||
pVal = Tcl_NewIntObj(v);
|
pVal = Tcl_NewIntObj((int)v);
|
||||||
}else{
|
}else{
|
||||||
pVal = Tcl_NewWideIntObj(v);
|
pVal = Tcl_NewWideIntObj(v);
|
||||||
}
|
}
|
||||||
@@ -1485,7 +1485,7 @@ static Tcl_Obj *dbEvalColumnValue(DbEvalContext *p, int iCol){
|
|||||||
case SQLITE_INTEGER: {
|
case SQLITE_INTEGER: {
|
||||||
sqlite_int64 v = sqlite3_column_int64(pStmt, iCol);
|
sqlite_int64 v = sqlite3_column_int64(pStmt, iCol);
|
||||||
if( v>=-2147483647 && v<=2147483647 ){
|
if( v>=-2147483647 && v<=2147483647 ){
|
||||||
return Tcl_NewIntObj(v);
|
return Tcl_NewIntObj((int)v);
|
||||||
}else{
|
}else{
|
||||||
return Tcl_NewWideIntObj(v);
|
return Tcl_NewWideIntObj(v);
|
||||||
}
|
}
|
||||||
@@ -2452,7 +2452,7 @@ static int DbObjCmd(void *cd, Tcl_Interp *interp, int objc,Tcl_Obj *const*objv){
|
|||||||
}
|
}
|
||||||
if( zNull && len>0 ){
|
if( zNull && len>0 ){
|
||||||
pDb->zNull = Tcl_Alloc( len + 1 );
|
pDb->zNull = Tcl_Alloc( len + 1 );
|
||||||
strncpy(pDb->zNull, zNull, len);
|
memcpy(pDb->zNull, zNull, len);
|
||||||
pDb->zNull[len] = '\0';
|
pDb->zNull[len] = '\0';
|
||||||
}else{
|
}else{
|
||||||
pDb->zNull = 0;
|
pDb->zNull = 0;
|
||||||
|
@@ -231,11 +231,7 @@ static void set_options(Tcl_Interp *interp){
|
|||||||
Tcl_SetVar2(interp, "sqlite_options", "compound", "1", TCL_GLOBAL_ONLY);
|
Tcl_SetVar2(interp, "sqlite_options", "compound", "1", TCL_GLOBAL_ONLY);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef SQLITE_OMIT_CONFLICT_CLAUSE
|
|
||||||
Tcl_SetVar2(interp, "sqlite_options", "conflict", "0", TCL_GLOBAL_ONLY);
|
|
||||||
#else
|
|
||||||
Tcl_SetVar2(interp, "sqlite_options", "conflict", "1", TCL_GLOBAL_ONLY);
|
Tcl_SetVar2(interp, "sqlite_options", "conflict", "1", TCL_GLOBAL_ONLY);
|
||||||
#endif
|
|
||||||
|
|
||||||
#if SQLITE_OS_UNIX
|
#if SQLITE_OS_UNIX
|
||||||
Tcl_SetVar2(interp, "sqlite_options", "crashtest", "1", TCL_GLOBAL_ONLY);
|
Tcl_SetVar2(interp, "sqlite_options", "crashtest", "1", TCL_GLOBAL_ONLY);
|
||||||
|
@@ -404,7 +404,7 @@ static int clock_seconds_proc(
|
|||||||
*/
|
*/
|
||||||
typedef struct UnlockNotification UnlockNotification;
|
typedef struct UnlockNotification UnlockNotification;
|
||||||
struct UnlockNotification {
|
struct UnlockNotification {
|
||||||
int fired; /* True after unlock event has occured */
|
int fired; /* True after unlock event has occurred */
|
||||||
pthread_cond_t cond; /* Condition variable to wait on */
|
pthread_cond_t cond; /* Condition variable to wait on */
|
||||||
pthread_mutex_t mutex; /* Mutex to protect structure */
|
pthread_mutex_t mutex; /* Mutex to protect structure */
|
||||||
};
|
};
|
||||||
|
16
src/vdbe.c
16
src/vdbe.c
@@ -807,7 +807,7 @@ case OP_Yield: { /* in1 */
|
|||||||
|
|
||||||
/* Opcode: HaltIfNull P1 P2 P3 P4 *
|
/* Opcode: HaltIfNull P1 P2 P3 P4 *
|
||||||
**
|
**
|
||||||
** Check the value in register P3. If is is NULL then Halt using
|
** Check the value in register P3. If it is NULL then Halt using
|
||||||
** parameter P1, P2, and P4 as if this were a Halt instruction. If the
|
** parameter P1, P2, and P4 as if this were a Halt instruction. If the
|
||||||
** value in register P3 is not NULL, then this routine is a no-op.
|
** value in register P3 is not NULL, then this routine is a no-op.
|
||||||
*/
|
*/
|
||||||
@@ -1730,7 +1730,7 @@ case OP_ToReal: { /* same as TK_TO_REAL, in1 */
|
|||||||
** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either
|
** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either
|
||||||
** true or false and is never NULL. If both operands are NULL then the result
|
** true or false and is never NULL. If both operands are NULL then the result
|
||||||
** of comparison is false. If either operand is NULL then the result is true.
|
** of comparison is false. If either operand is NULL then the result is true.
|
||||||
** If neither operand is NULL the the result is the same as it would be if
|
** If neither operand is NULL the result is the same as it would be if
|
||||||
** the SQLITE_NULLEQ flag were omitted from P5.
|
** the SQLITE_NULLEQ flag were omitted from P5.
|
||||||
*/
|
*/
|
||||||
/* Opcode: Eq P1 P2 P3 P4 P5
|
/* Opcode: Eq P1 P2 P3 P4 P5
|
||||||
@@ -1742,7 +1742,7 @@ case OP_ToReal: { /* same as TK_TO_REAL, in1 */
|
|||||||
** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either
|
** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either
|
||||||
** true or false and is never NULL. If both operands are NULL then the result
|
** true or false and is never NULL. If both operands are NULL then the result
|
||||||
** of comparison is true. If either operand is NULL then the result is false.
|
** of comparison is true. If either operand is NULL then the result is false.
|
||||||
** If neither operand is NULL the the result is the same as it would be if
|
** If neither operand is NULL the result is the same as it would be if
|
||||||
** the SQLITE_NULLEQ flag were omitted from P5.
|
** the SQLITE_NULLEQ flag were omitted from P5.
|
||||||
*/
|
*/
|
||||||
/* Opcode: Le P1 P2 P3 P4 P5
|
/* Opcode: Le P1 P2 P3 P4 P5
|
||||||
@@ -2021,13 +2021,13 @@ case OP_BitNot: { /* same as TK_BITNOT, in1, out2 */
|
|||||||
|
|
||||||
/* Opcode: If P1 P2 P3 * *
|
/* Opcode: If P1 P2 P3 * *
|
||||||
**
|
**
|
||||||
** Jump to P2 if the value in register P1 is true. The value is
|
** Jump to P2 if the value in register P1 is true. The value
|
||||||
** is considered true if it is numeric and non-zero. If the value
|
** is considered true if it is numeric and non-zero. If the value
|
||||||
** in P1 is NULL then take the jump if P3 is true.
|
** in P1 is NULL then take the jump if P3 is true.
|
||||||
*/
|
*/
|
||||||
/* Opcode: IfNot P1 P2 P3 * *
|
/* Opcode: IfNot P1 P2 P3 * *
|
||||||
**
|
**
|
||||||
** Jump to P2 if the value in register P1 is False. The value is
|
** Jump to P2 if the value in register P1 is False. The value
|
||||||
** is considered true if it has a numeric value of zero. If the value
|
** is considered true if it has a numeric value of zero. If the value
|
||||||
** in P1 is NULL then take the jump if P3 is true.
|
** in P1 is NULL then take the jump if P3 is true.
|
||||||
*/
|
*/
|
||||||
@@ -3645,7 +3645,7 @@ case OP_IsUnique: { /* jump, in3 */
|
|||||||
|
|
||||||
/* Opcode: NotExists P1 P2 P3 * *
|
/* Opcode: NotExists P1 P2 P3 * *
|
||||||
**
|
**
|
||||||
** Use the content of register P3 as a integer key. If a record
|
** Use the content of register P3 as an integer key. If a record
|
||||||
** with that key does not exist in table of P1, then jump to P2.
|
** with that key does not exist in table of P1, then jump to P2.
|
||||||
** If the record does exist, then fall through. The cursor is left
|
** If the record does exist, then fall through. The cursor is left
|
||||||
** pointing to the record if it exists.
|
** pointing to the record if it exists.
|
||||||
@@ -3721,7 +3721,7 @@ case OP_Sequence: { /* out2-prerelease */
|
|||||||
** If P3>0 then P3 is a register in the root frame of this VDBE that holds
|
** If P3>0 then P3 is a register in the root frame of this VDBE that holds
|
||||||
** the largest previously generated record number. No new record numbers are
|
** the largest previously generated record number. No new record numbers are
|
||||||
** allowed to be less than this value. When this value reaches its maximum,
|
** allowed to be less than this value. When this value reaches its maximum,
|
||||||
** a SQLITE_FULL error is generated. The P3 register is updated with the '
|
** an SQLITE_FULL error is generated. The P3 register is updated with the '
|
||||||
** generated record number. This P3 mechanism is used to help implement the
|
** generated record number. This P3 mechanism is used to help implement the
|
||||||
** AUTOINCREMENT feature.
|
** AUTOINCREMENT feature.
|
||||||
*/
|
*/
|
||||||
@@ -4387,7 +4387,7 @@ case OP_Next: { /* jump */
|
|||||||
|
|
||||||
/* Opcode: IdxInsert P1 P2 P3 * P5
|
/* Opcode: IdxInsert P1 P2 P3 * P5
|
||||||
**
|
**
|
||||||
** Register P2 holds a SQL index key made using the
|
** Register P2 holds an SQL index key made using the
|
||||||
** MakeRecord instructions. This opcode writes that key
|
** MakeRecord instructions. This opcode writes that key
|
||||||
** into the index P1. Data for the entry is nil.
|
** into the index P1. Data for the entry is nil.
|
||||||
**
|
**
|
||||||
|
@@ -440,7 +440,7 @@ do_delete_tests e_delete-3.9 -repair rebuild_t1 -query {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
# EVIDENCE-OF: R-26627-30313 The ORDER BY clause on an DELETE statement
|
# EVIDENCE-OF: R-07548-13422 The ORDER BY clause on a DELETE statement
|
||||||
# is used only to determine which rows fall within the LIMIT. The order
|
# is used only to determine which rows fall within the LIMIT. The order
|
||||||
# in which rows are deleted is arbitrary and is not influenced by the
|
# in which rows are deleted is arbitrary and is not influenced by the
|
||||||
# ORDER BY clause.
|
# ORDER BY clause.
|
||||||
|
@@ -1598,8 +1598,8 @@ do_expr_test e_expr-31.1.2 { CAST(1.99999 AS INTEGER) } integer 1
|
|||||||
do_expr_test e_expr-31.1.3 { CAST(-1.99999 AS INTEGER) } integer -1
|
do_expr_test e_expr-31.1.3 { CAST(-1.99999 AS INTEGER) } integer -1
|
||||||
do_expr_test e_expr-31.1.4 { CAST(-0.99999 AS INTEGER) } integer 0
|
do_expr_test e_expr-31.1.4 { CAST(-0.99999 AS INTEGER) } integer 0
|
||||||
|
|
||||||
# EVIDENCE-OF: R-06126-36021 If an REAL is too large to be represented
|
# EVIDENCE-OF: R-49503-28105 If a REAL is too large to be represented as
|
||||||
# as an INTEGER then the result of the cast is the largest negative
|
# an INTEGER then the result of the cast is the largest negative
|
||||||
# integer: -9223372036854775808.
|
# integer: -9223372036854775808.
|
||||||
#
|
#
|
||||||
do_expr_test e_expr-31.2.1 { CAST(2e+50 AS INT) } integer -9223372036854775808
|
do_expr_test e_expr-31.2.1 { CAST(2e+50 AS INT) } integer -9223372036854775808
|
||||||
@@ -1845,4 +1845,3 @@ foreach {tn expr} {
|
|||||||
|
|
||||||
|
|
||||||
finish_test
|
finish_test
|
||||||
|
|
||||||
|
@@ -152,7 +152,7 @@ do_insert_tests e_insert-1.2 -error {
|
|||||||
4 "INSERT INTO a2 VALUES(1,2,3,4,5)" {a2 3 5}
|
4 "INSERT INTO a2 VALUES(1,2,3,4,5)" {a2 3 5}
|
||||||
}
|
}
|
||||||
|
|
||||||
# EVIDENCE-OF: R-52422-65517 In this case the result of evaluting the
|
# EVIDENCE-OF: R-04006-57648 In this case the result of evaluating the
|
||||||
# left-most expression in the VALUES list is inserted into the left-most
|
# left-most expression in the VALUES list is inserted into the left-most
|
||||||
# column of the new row, and so on.
|
# column of the new row, and so on.
|
||||||
#
|
#
|
||||||
|
@@ -1768,9 +1768,9 @@ do_select_tests e_select-8.5 {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# EVIDENCE-OF: R-27923-38747 Otherwise, if the ORDER BY expression is
|
# EVIDENCE-OF: R-65068-27207 Otherwise, if the ORDER BY expression is
|
||||||
# any other expression, it is evaluated and the the returned value used
|
# any other expression, it is evaluated and the returned value used to
|
||||||
# to order the output rows.
|
# order the output rows.
|
||||||
#
|
#
|
||||||
# EVIDENCE-OF: R-03421-57988 If the SELECT statement is a simple SELECT,
|
# EVIDENCE-OF: R-03421-57988 If the SELECT statement is a simple SELECT,
|
||||||
# then an ORDER BY may contain any arbitrary expressions.
|
# then an ORDER BY may contain any arbitrary expressions.
|
||||||
|
@@ -233,9 +233,9 @@ do_update_tests e_update-1.5 -query {
|
|||||||
{3 1 4 1 5 9 2 6 5}
|
{3 1 4 1 5 9 2 6 5}
|
||||||
}
|
}
|
||||||
|
|
||||||
# EVIDENCE-OF: R-09060-20018 If a single column-name appears more than
|
# EVIDENCE-OF: R-34751-18293 If a single column-name appears more than
|
||||||
# once in the list of assignment expressions, all but the rightmost
|
# once in the list of assignment expressions, all but the rightmost
|
||||||
# occurence is ignored.
|
# occurrence is ignored.
|
||||||
#
|
#
|
||||||
do_update_tests e_update-1.6 -query {
|
do_update_tests e_update-1.6 -query {
|
||||||
SELECT * FROM t2
|
SELECT * FROM t2
|
||||||
@@ -605,4 +605,3 @@ do_update_tests e_update-3.5 -query { SELECT x FROM t8 ; DELETE FROM t8 } {
|
|||||||
} ;# ifcapable update_delete_limit
|
} ;# ifcapable update_delete_limit
|
||||||
|
|
||||||
finish_test
|
finish_test
|
||||||
|
|
||||||
|
@@ -48,8 +48,8 @@ proc open_uri_error {uri} {
|
|||||||
# and the filename argument begins with "file:", then the filename is
|
# and the filename argument begins with "file:", then the filename is
|
||||||
# interpreted as a URI.
|
# interpreted as a URI.
|
||||||
#
|
#
|
||||||
# EVIDENCE-OF: R-32637-34037 URI filename interpretation is enabled if
|
# EVIDENCE-OF: R-24124-56960 URI filename interpretation is enabled if
|
||||||
# the SQLITE_OPEN_URI flag is is set in the fourth argument to
|
# the SQLITE_OPEN_URI flag is set in the fourth argument to
|
||||||
# sqlite3_open_v2(), or if it has been enabled globally using the
|
# sqlite3_open_v2(), or if it has been enabled globally using the
|
||||||
# SQLITE_CONFIG_URI option with the sqlite3_config() method or by the
|
# SQLITE_CONFIG_URI option with the sqlite3_config() method or by the
|
||||||
# SQLITE_USE_URI compile-time option.
|
# SQLITE_USE_URI compile-time option.
|
||||||
|
@@ -61,19 +61,17 @@ foreach enc $encodings {
|
|||||||
|
|
||||||
set k 1
|
set k 1
|
||||||
foreach val $vals {
|
foreach val $vals {
|
||||||
for {set x 1} {$x<18} {incr x} {
|
for {set x 1} {$x<16} {incr x} {
|
||||||
set part [expr $init + [string range $val 0 [expr $x-1]]]
|
set part [expr $init + [string range $val 0 [expr $x-1]]]
|
||||||
regsub {e\+0} $part {e+} part
|
|
||||||
regsub {^1e} $part {1.0e} part
|
|
||||||
|
|
||||||
do_test enc4-$i.$j.$k.3.$x {
|
do_realnum_test enc4-$i.$j.$k.3.$x {
|
||||||
sqlite3_reset $S
|
sqlite3_reset $S
|
||||||
sqlite3_bind_text $S 1 $val $x
|
sqlite3_bind_text $S 1 $val $x
|
||||||
sqlite3_step $S
|
sqlite3_step $S
|
||||||
sqlite3_column_text $S 0
|
sqlite3_column_text $S 0
|
||||||
} [list $part]
|
} [list $part]
|
||||||
|
|
||||||
do_test enc4-$i.$j.$k.4.$x {
|
do_realnum_test enc4-$i.$j.$k.4.$x {
|
||||||
sqlite3_reset $S
|
sqlite3_reset $S
|
||||||
sqlite3_bind_text16 $S 1 [encoding convertto unicode $val] [expr $x*2]
|
sqlite3_bind_text16 $S 1 [encoding convertto unicode $val] [expr $x*2]
|
||||||
sqlite3_step $S
|
sqlite3_step $S
|
||||||
|
@@ -21,10 +21,6 @@ ifcapable !fts3 {
|
|||||||
finish_test
|
finish_test
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if {[db eval {SELECT sqlite_compileoption_used('ENABLE_FTS4')}]==0} {
|
|
||||||
finish_test
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
do_test fts4aa-1.0 {
|
do_test fts4aa-1.0 {
|
||||||
db eval {
|
db eval {
|
||||||
@@ -1589,19 +1585,19 @@ db func mit mit
|
|||||||
|
|
||||||
do_test fts4aa-2.1 {
|
do_test fts4aa-2.1 {
|
||||||
db eval {
|
db eval {
|
||||||
SELECT docid, mit(matchinfo(t1)) FROM t1 WHERE t1 MATCH 'melchizedek';
|
SELECT docid, mit(matchinfo(t1, 'pcxnal')) FROM t1 WHERE t1 MATCH 'melchizedek';
|
||||||
}
|
}
|
||||||
} {1014018 {1 1 1 1 1 1533 25 20}}
|
} {1014018 {1 1 1 1 1 1533 25 20}}
|
||||||
do_test fts4aa-2.2 {
|
do_test fts4aa-2.2 {
|
||||||
db eval {
|
db eval {
|
||||||
SELECT docid, mit(matchinfo(t1)) FROM t1
|
SELECT docid, mit(matchinfo(t1, 'pcxnal')) FROM t1
|
||||||
WHERE t1 MATCH 'spake hebrew'
|
WHERE t1 MATCH 'spake hebrew'
|
||||||
ORDER BY docid;
|
ORDER BY docid;
|
||||||
}
|
}
|
||||||
} {1039014 {2 1 1 40 40 1 6 6 1533 25 42} 1039017 {2 1 1 40 40 1 6 6 1533 25 26}}
|
} {1039014 {2 1 1 40 40 1 6 6 1533 25 42} 1039017 {2 1 1 40 40 1 6 6 1533 25 26}}
|
||||||
do_test fts4aa-2.3 {
|
do_test fts4aa-2.3 {
|
||||||
db eval {
|
db eval {
|
||||||
SELECT docid, mit(matchinfo(t1)) FROM t1
|
SELECT docid, mit(matchinfo(t1, 'pcxnal')) FROM t1
|
||||||
WHERE t1 MATCH 'laban overtook jacob'
|
WHERE t1 MATCH 'laban overtook jacob'
|
||||||
ORDER BY docid;
|
ORDER BY docid;
|
||||||
}
|
}
|
||||||
@@ -1613,7 +1609,7 @@ do_test fts4aa-9.1 {
|
|||||||
SELECT hex(size) FROM t1_docsize;
|
SELECT hex(size) FROM t1_docsize;
|
||||||
SELECT hex(value) FROM t1_stat;
|
SELECT hex(value) FROM t1_stat;
|
||||||
}
|
}
|
||||||
} {17 0117}
|
} {17 01176F}
|
||||||
|
|
||||||
do_test fts4aa-9.2 {
|
do_test fts4aa-9.2 {
|
||||||
db eval {
|
db eval {
|
||||||
@@ -1626,11 +1622,12 @@ do_test fts4aa-9.3 {
|
|||||||
}
|
}
|
||||||
} {}
|
} {}
|
||||||
do_test fts4aa-9.4 {
|
do_test fts4aa-9.4 {
|
||||||
|
# Note: Token 'in' is being deferred in the following query.
|
||||||
db eval {
|
db eval {
|
||||||
SELECT docid, mit(matchinfo(t1)) FROM t1
|
SELECT docid, mit(matchinfo(t1, 'pcxnal')) FROM t1
|
||||||
WHERE t1 MATCH 'joseph died in egypt'
|
WHERE t1 MATCH 'joseph died in egypt'
|
||||||
ORDER BY docid;
|
ORDER BY docid;
|
||||||
}
|
}
|
||||||
} {1050026 {4 1 1 1 1 1 1 1 2 2 1 1 1 1 1 23 23}}
|
} {1050026 {4 1 1 1 1 1 1 1 2 1 1 1 1 1 1 23 23}}
|
||||||
|
|
||||||
finish_test
|
finish_test
|
||||||
|
@@ -355,7 +355,8 @@ proc do_test {name cmd expected} {
|
|||||||
}
|
}
|
||||||
|
|
||||||
proc realnum_normalize {r} {
|
proc realnum_normalize {r} {
|
||||||
string map {1.#INF inf} [regsub -all {(e[+-])0+} $r {\1}]
|
# different TCL versions display floating point values differently.
|
||||||
|
string map {1.#INF inf Inf inf .0e e} [regsub -all {(e[+-])0+} $r {\1}]
|
||||||
}
|
}
|
||||||
proc do_realnum_test {name cmd expected} {
|
proc do_realnum_test {name cmd expected} {
|
||||||
uplevel [list do_test $name [
|
uplevel [list do_test $name [
|
||||||
|
37
tool/lemon.c
37
tool/lemon.c
@@ -41,23 +41,6 @@ extern int access(const char *path, int mode);
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
static int showPrecedenceConflict = 0;
|
static int showPrecedenceConflict = 0;
|
||||||
static const char **made_files = NULL;
|
|
||||||
static int made_files_count = 0;
|
|
||||||
static int successful_exit = 0;
|
|
||||||
static void LemonAtExit(void)
|
|
||||||
{
|
|
||||||
/* if we failed, delete (most) files we made, to unconfuse build tools. */
|
|
||||||
int i;
|
|
||||||
for (i = 0; i < made_files_count; i++) {
|
|
||||||
if (!successful_exit) {
|
|
||||||
remove(made_files[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
free(made_files);
|
|
||||||
made_files_count = 0;
|
|
||||||
made_files = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
static char *msort(char*,char**,int(*)(const char*,const char*));
|
static char *msort(char*,char**,int(*)(const char*,const char*));
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -1433,8 +1416,6 @@ int main(int argc, char **argv)
|
|||||||
int exitcode;
|
int exitcode;
|
||||||
struct lemon lem;
|
struct lemon lem;
|
||||||
|
|
||||||
atexit(LemonAtExit);
|
|
||||||
|
|
||||||
OptInit(argv,options,stderr);
|
OptInit(argv,options,stderr);
|
||||||
if( version ){
|
if( version ){
|
||||||
printf("Lemon version 1.0\n");
|
printf("Lemon version 1.0\n");
|
||||||
@@ -1537,7 +1518,6 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
/* return 0 on success, 1 on failure. */
|
/* return 0 on success, 1 on failure. */
|
||||||
exitcode = ((lem.errorcnt > 0) || (lem.nconflict > 0)) ? 1 : 0;
|
exitcode = ((lem.errorcnt > 0) || (lem.nconflict > 0)) ? 1 : 0;
|
||||||
successful_exit = (exitcode == 0);
|
|
||||||
exit(exitcode);
|
exit(exitcode);
|
||||||
return (exitcode);
|
return (exitcode);
|
||||||
}
|
}
|
||||||
@@ -2761,23 +2741,6 @@ PRIVATE FILE *file_open(
|
|||||||
lemp->errorcnt++;
|
lemp->errorcnt++;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Add files we create to a list, so we can delete them if we fail. This
|
|
||||||
** is to keep makefiles from getting confused. We don't include .out files,
|
|
||||||
** though: this is debug information, and you don't want it deleted if there
|
|
||||||
** was an error you need to track down.
|
|
||||||
*/
|
|
||||||
if(( *mode=='w' ) && (strcmp(suffix, ".out") != 0)){
|
|
||||||
const char **ptr = (const char **)
|
|
||||||
realloc(made_files, sizeof (const char **) * (made_files_count + 1));
|
|
||||||
const char *fname = Strsafe(lemp->outname);
|
|
||||||
if ((ptr == NULL) || (fname == NULL)) {
|
|
||||||
free(ptr);
|
|
||||||
memory_error();
|
|
||||||
}
|
|
||||||
made_files = ptr;
|
|
||||||
made_files[made_files_count++] = fname;
|
|
||||||
}
|
|
||||||
return fp;
|
return fp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -47,7 +47,7 @@ close $in
|
|||||||
#
|
#
|
||||||
set out [open sqlite3.c w]
|
set out [open sqlite3.c w]
|
||||||
# Force the output to use unix line endings, even on Windows.
|
# Force the output to use unix line endings, even on Windows.
|
||||||
# fconfigure $out -translation lf
|
fconfigure $out -translation lf
|
||||||
set today [clock format [clock seconds] -format "%Y-%m-%d %H:%M:%S UTC" -gmt 1]
|
set today [clock format [clock seconds] -format "%Y-%m-%d %H:%M:%S UTC" -gmt 1]
|
||||||
puts $out [subst \
|
puts $out [subst \
|
||||||
{/******************************************************************************
|
{/******************************************************************************
|
||||||
|
Reference in New Issue
Block a user