From: drh Date: Sat, 11 Apr 2009 16:27:19 +0000 (+0000) Subject: Add a comments and an assert() to the virtual table implementation. X-Git-Tag: version-3.6.15~253 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=63842415bdeaa7738394e99130ebc6a25220fa25;p=thirdparty%2Fsqlite.git Add a comments and an assert() to the virtual table implementation. No functional changes. (CVS 6497) FossilOrigin-Name: ac5d0c0aa1de687bde972fbf0db8f04508825205 --- diff --git a/manifest b/manifest index 2c55036132..d99067b4c1 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Fix\sa\scase\swhere\sa\scorrupt\sdatabase\scould\scause\san\sassert()\sto\sfail.\s(CVS\s6496) -D 2009-04-11T16:06:15 +C Add\sa\scomments\sand\san\sassert()\sto\sthe\svirtual\stable\simplementation.\nNo\sfunctional\schanges.\s(CVS\s6497) +D 2009-04-11T16:27:20 F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0 F Makefile.in 583e87706abc3026960ed759aff6371faf84c211 F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654 @@ -207,7 +207,7 @@ F src/vdbeapi.c 0d4138c79db48e88a497b09d257c384911a24047 F src/vdbeaux.c 5ecb4c7a041b8926a8927b1a27bcbb8ff74ae5c4 F src/vdbeblob.c e67757450ae8581a8b354d9d7e467e41502dfe38 F src/vdbemem.c 9798905787baae83d0b53b62030e32ecf7a0586f -F src/vtab.c f1aba5a6dc1f83b97a39fbbc58ff8cbc76311347 +F src/vtab.c 6118d71c5137e20a7ac51fb5d9beb0361fbedb89 F src/walker.c 7cdf63223c953d4343c6833e940f110281a378ee F src/where.c ddf26069d03f9e0c6ef14d537422df02e0c593f0 F test/aggerror.test a867e273ef9e3d7919f03ef4f0e8c0d2767944f2 @@ -717,7 +717,7 @@ F tool/speedtest16.c c8a9c793df96db7e4933f0852abb7a03d48f2e81 F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224 F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e -P 5484419294356b704c2c9064f36ed254875ca8c0 -R 2e96b765f3ae6df475f1d5f1c48e8aa8 -U danielk1977 -Z 8f3345f1abea5eb987e939cee8d0e3ce +P 2c560e057e1da8a603efc36deea036f2392a4ab9 +R c933794e7ad3da191304723b50287bf2 +U drh +Z 1604cbd2809b3455fe72d9ed10306c85 diff --git a/manifest.uuid b/manifest.uuid index 4367021ccf..e1e437eda4 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -2c560e057e1da8a603efc36deea036f2392a4ab9 \ No newline at end of file +ac5d0c0aa1de687bde972fbf0db8f04508825205 \ No newline at end of file diff --git a/src/vtab.c b/src/vtab.c index bfa88e9db2..e2103bdbc3 100644 --- a/src/vtab.c +++ b/src/vtab.c @@ -11,11 +11,16 @@ ************************************************************************* ** This file contains code used to help implement virtual tables. ** -** $Id: vtab.c,v 1.84 2009/03/24 15:08:10 drh Exp $ +** $Id: vtab.c,v 1.85 2009/04/11 16:27:20 drh Exp $ */ #ifndef SQLITE_OMIT_VIRTUALTABLE #include "sqliteInt.h" +/* +** The actual function that does the work of creating a new module. +** This function implements the sqlite3_create_module() and +** sqlite3_create_module_v2() interfaces. +*/ static int createModule( sqlite3 *db, /* Database in which module is registered */ const char *zName, /* Name assigned to this module */ @@ -97,6 +102,7 @@ void sqlite3VtabLock(sqlite3_vtab *pVtab){ ** disconnect the virtual table. */ void sqlite3VtabUnlock(sqlite3 *db, sqlite3_vtab *pVtab){ + assert( pVtab->nRef>0 ); pVtab->nRef--; assert(db); assert( sqlite3SafetyCheckOk(db) );