MCPcopy Create free account
hub / github.com/GaijinEntertainment/daScript / recoverSqlCallback

Function recoverSqlCallback

modules/dasSQLITE/sqlite/shell.c:14342–14349  ·  view source on GitHub ↗

** If this recover handle is not in SQL callback mode (i.e. was not created ** using sqlite3_recover_init_sql()) of if an error has already occurred, ** this function is a no-op. Otherwise, issue a callback with SQL statement ** zSql as the parameter. ** ** If the callback returns non-zero, set the recover handle error code to ** the value returned (so that the caller will abandon processing).

Source from the content-addressed store, hash-verified

14340** the value returned (so that the caller will abandon processing).
14341*/
14342static void recoverSqlCallback(sqlite3_recover *p, const char *zSql){
14343 if( p->errCode==SQLITE_OK && p->xSql ){
14344 int res = p->xSql(p->pSqlCtx, zSql);
14345 if( res ){
14346 recoverError(p, SQLITE_ERROR, "callback returned an error - %d", res);
14347 }
14348 }
14349}
14350
14351/*
14352** Transfer the following settings from the input database to the output

Callers 7

recoverTransferSettingsFunction · 0.85
recoverWriteSchema1Function · 0.85
recoverWriteSchema2Function · 0.85
recoverWriteDataStepFunction · 0.85
recoverStepFunction · 0.85

Calls 1

recoverErrorFunction · 0.85

Tested by

no test coverage detected