1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Begin adding the sqlite3session_patchset() API to the sessions extension. This is an interim commit.

FossilOrigin-Name: 60a4565a8c44762a002cd02979317df5ca47e899
This commit is contained in:
dan
2014-08-15 20:15:49 +00:00
parent f3a3dfe9f1
commit 73b3c05590
6 changed files with 435 additions and 49 deletions

View File

@ -73,6 +73,7 @@ static int test_session_cmd(
{ "indirect", 1, "BOOL", }, /* 4 */
{ "isempty", 0, "", }, /* 5 */
{ "table_filter", 1, "SCRIPT", }, /* 6 */
{ "patchset", 0, "", }, /* 7 */
{ 0 }
};
int iSub;
@ -102,10 +103,15 @@ static int test_session_cmd(
break;
}
case 7: /* patchset */
case 1: { /* changeset */
int nChange;
void *pChange;
rc = sqlite3session_changeset(pSession, &nChange, &pChange);
if( iSub==7 ){
rc = sqlite3session_patchset(pSession, &nChange, &pChange);
}else{
rc = sqlite3session_changeset(pSession, &nChange, &pChange);
}
if( rc==SQLITE_OK ){
Tcl_SetObjResult(interp, Tcl_NewByteArrayObj(pChange, nChange));
sqlite3_free(pChange);