mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
Check the validity of the database connection before the trace callback,
not afterwards. (CVS 837) FossilOrigin-Name: 960a2e4af3b940d74a82f98e8bf19aeec88a05ce
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
** other files are for internal use by SQLite and should not be
|
||||
** accessed by users of the library.
|
||||
**
|
||||
** $Id: main.c,v 1.107 2003/01/16 16:28:54 drh Exp $
|
||||
** $Id: main.c,v 1.108 2003/01/18 17:04:09 drh Exp $
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
#include "os.h"
|
||||
@@ -602,11 +602,11 @@ int sqlite_exec(
|
||||
){
|
||||
Parse sParse;
|
||||
|
||||
if( pzErrMsg ) *pzErrMsg = 0;
|
||||
if( sqliteSafetyOn(db) ) goto exec_misuse;
|
||||
#ifndef SQLITE_OMIT_TRACE
|
||||
if( db->xTrace ) db->xTrace(db->pTraceArg, zSql);
|
||||
#endif
|
||||
if( pzErrMsg ) *pzErrMsg = 0;
|
||||
if( sqliteSafetyOn(db) ) goto exec_misuse;
|
||||
if( (db->flags & SQLITE_Initialized)==0 ){
|
||||
int rc, cnt = 1;
|
||||
while( (rc = sqliteInit(db, pzErrMsg))==SQLITE_BUSY
|
||||
|
Reference in New Issue
Block a user