From: dan Date: Tue, 11 Aug 2015 10:59:10 +0000 (+0000) Subject: Add a tcl interface for the experimental logging functionality. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7e15571ab549ebe325425a7f243c0c468fd6108a;p=thirdparty%2Fsqlite.git Add a tcl interface for the experimental logging functionality. FossilOrigin-Name: e844304de7c7d50c4c22c2633bbfef146dfc0be1 --- diff --git a/manifest b/manifest index 496c56bafc..0cc1e148d8 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Two\smore\splaces\swhere\slogging\sof\sfreelist\strunk\spages\sis\sneeded. -D 2015-08-11T01:45:40.842 +C Add\sa\stcl\sinterface\sfor\sthe\sexperimental\slogging\sfunctionality. +D 2015-08-11T10:59:10.502 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f F Makefile.in 2fc9ca6bf5949d415801c007ed3004a4bdb7c380 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23 @@ -343,7 +343,7 @@ F src/sqliteInt.h e1a5cfe6c44606429838fa9bbd1824e119e05533 F src/sqliteLimit.h 216557999cb45f2e3578ed53ebefe228d779cb46 F src/status.c f266ad8a2892d659b74f0f50cb6a88b6e7c12179 F src/table.c 51b46b2a62d1b3a959633d593b89bab5e2c9155e -F src/tclsqlite.c d9439b6a910985b7fff43ba6756bcef00de22649 +F src/tclsqlite.c 1a7b57f3ae892d1a1395b5f1399b6da017b6ad07 F src/test1.c d339ae9b9baf9221c657c9628c9061d88bd831f6 F src/test2.c 577961fe48961b2f2e5c8b56ee50c3f459d3359d F src/test3.c 64d2afdd68feac1bb5e2ffb8226c8c639f798622 @@ -1372,7 +1372,7 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4 F tool/warnings.sh 48bd54594752d5be3337f12c72f28d2080cb630b F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f -P bb5d7782bdc73748e54d202ddd7b082c6ee58ebf -R 7e2f12926f4b9606ffb30253d4c3e54d -U drh -Z 73ca44279f623e57ac6764f7bf62b8d1 +P 56ff336e0ae258f4ac0b221602012f5fa9b4fc13 +R 5629348888d243af0301b3978d508e8e +U dan +Z 1b223765ca5b62bf8b60ddefbeb58e37 diff --git a/manifest.uuid b/manifest.uuid index 30efa835de..9962accb95 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -56ff336e0ae258f4ac0b221602012f5fa9b4fc13 \ No newline at end of file +e844304de7c7d50c4c22c2633bbfef146dfc0be1 \ No newline at end of file diff --git a/src/tclsqlite.c b/src/tclsqlite.c index f024317e90..6150c4e929 100644 --- a/src/tclsqlite.c +++ b/src/tclsqlite.c @@ -1636,6 +1636,7 @@ static int DbObjCmd(void *cd, Tcl_Interp *interp, int objc,Tcl_Obj *const*objv){ "collate", "collation_needed", "commit_hook", "complete", "copy", "enable_load_extension", "errorcode", "eval", "exists", + "experimental_log_open", "function", "incrblob", "interrupt", "last_insert_rowid", "nullvalue", "onecolumn", "profile", "progress", "rekey", @@ -1650,6 +1651,7 @@ static int DbObjCmd(void *cd, Tcl_Interp *interp, int objc,Tcl_Obj *const*objv){ DB_COLLATE, DB_COLLATION_NEEDED, DB_COMMIT_HOOK, DB_COMPLETE, DB_COPY, DB_ENABLE_LOAD_EXTENSION, DB_ERRORCODE, DB_EVAL, DB_EXISTS, + DB_EXPERIMENTAL_LOG_OPEN, DB_FUNCTION, DB_INCRBLOB, DB_INTERRUPT, DB_LAST_INSERT_ROWID, DB_NULLVALUE, DB_ONECOLUMN, DB_PROFILE, DB_PROGRESS, DB_REKEY, @@ -2319,6 +2321,25 @@ static int DbObjCmd(void *cd, Tcl_Interp *interp, int objc,Tcl_Obj *const*objv){ break; } + /* + ** $db experimental_log_open ?FILENAME? + ** + ** Invoke the sqlite3_experimental_log_open() API. This code is not for + ** release. + */ + case DB_EXPERIMENTAL_LOG_OPEN: { + char *zFile = 0; + if( objc>3 ){ + Tcl_WrongNumArgs(interp, 2, objv, "?FILENAME?"); + return TCL_ERROR; + } + if( objc==3 ){ + zFile = Tcl_GetString(objv[2]); + } + sqlite3_experimental_log_open(pDb->db, zFile); + break; + } + /* ** $db function NAME [-argcount N] [-deterministic] SCRIPT **