/ Check-in [0fb26c7b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Remove the _SafeInit() entry points from the TCL interface. They have long been no-ops. Removing them completely avoids confusion as to why they don't work.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 0fb26c7bfa7a4bb1503f90fd6f5b9c70f444665b
User & Date: drh 2012-03-20 15:10:42
Context
2012-03-22
12:50
Always quote the names of tables in the output of the shell's ".dump" command, even if the name is pure alphabetic text, in case the name is a keyword. check-in: 638b7115 user: drh tags: trunk
2012-03-20
17:04
Merge trunk changes into the fts4-incr-merge branch. check-in: f61d5fb0 user: drh tags: fts4-incr-merge
15:10
Remove the _SafeInit() entry points from the TCL interface. They have long been no-ops. Removing them completely avoids confusion as to why they don't work. check-in: 0fb26c7b user: drh tags: trunk
11:35
Version 3.7.11 check-in: 00bb9c9c user: drh tags: trunk, release, version-3.7.11
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/tclsqlite.c.

  3104   3104     */
  3105   3105     Tcl_CreateObjCommand(interp, "sqlite", (Tcl_ObjCmdProc*)DbMain, 0, 0);
  3106   3106   #endif
  3107   3107   
  3108   3108     return TCL_OK;
  3109   3109   }
  3110   3110   EXTERN int Tclsqlite3_Init(Tcl_Interp *interp){ return Sqlite3_Init(interp); }
  3111         -EXTERN int Sqlite3_SafeInit(Tcl_Interp *interp){ return TCL_OK; }
  3112         -EXTERN int Tclsqlite3_SafeInit(Tcl_Interp *interp){ return TCL_OK; }
  3113   3111   EXTERN int Sqlite3_Unload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3114   3112   EXTERN int Tclsqlite3_Unload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3115         -EXTERN int Sqlite3_SafeUnload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3116         -EXTERN int Tclsqlite3_SafeUnload(Tcl_Interp *interp, int flags){ return TCL_OK;}
  3117   3113   
         3114  +/* Because it accesses the file-system and uses persistent state, SQLite
         3115  +** is not considered appropriate for safe interpreters.  Hence, we deliberately
         3116  +** omit the _SafeInit() interfaces.
         3117  +*/
  3118   3118   
  3119   3119   #ifndef SQLITE_3_SUFFIX_ONLY
  3120   3120   int Sqlite_Init(Tcl_Interp *interp){ return Sqlite3_Init(interp); }
  3121   3121   int Tclsqlite_Init(Tcl_Interp *interp){ return Sqlite3_Init(interp); }
  3122         -int Sqlite_SafeInit(Tcl_Interp *interp){ return TCL_OK; }
  3123         -int Tclsqlite_SafeInit(Tcl_Interp *interp){ return TCL_OK; }
  3124   3122   int Sqlite_Unload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3125   3123   int Tclsqlite_Unload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3126         -int Sqlite_SafeUnload(Tcl_Interp *interp, int flags){ return TCL_OK; }
  3127         -int Tclsqlite_SafeUnload(Tcl_Interp *interp, int flags){ return TCL_OK;}
  3128   3124   #endif
  3129   3125   
  3130   3126   #ifdef TCLSH
  3131   3127   /*****************************************************************************
  3132   3128   ** All of the code that follows is used to build standalone TCL interpreters
  3133   3129   ** that are statically linked with SQLite.  Enable these by compiling
  3134   3130   ** with -DTCLSH=n where n can be 1 or 2.  An n of 1 generates a standard