System.Data.SQLite

Check-in [b5a342952a]
Login

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

Overview
Comment:Always attempt to log virtual table errors.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | virtualTables
Files: files | file ages | folders
SHA1: b5a342952a36268362475e66c749371c8b88c849
User & Date: mistachkin 2013-06-21 06:33:13.496
Context
2013-06-21
07:06
Add LogErrors and LogExceptions properties to the SQLiteModuleBase class. Allow the ISQLiteNativeModule implementation of the SQLiteModuleBase class to be overridden; however, remove it as a formal interface. check-in: deb17e28f2 user: mistachkin tags: virtualTables
06:33
Always attempt to log virtual table errors. check-in: b5a342952a user: mistachkin tags: virtualTables
06:27
Fix disposal semantics for classes derived from the SQLiteModuleBase class. Use the String.Format method consistently. Enable virtual table related native memory allocation tracking on the .NET Compact Framework. check-in: f9041807b3 user: mistachkin tags: virtualTables
Changes
Side-by-Side Diff Ignore Whitespace Patch
Changes to System.Data.SQLite/SQLiteModuleBase.cs.
2303
2304
2305
2306
2307
2308
2309











2310
2311
2312
2313
2314
2315
2316
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327







+
+
+
+
+
+
+
+
+
+
+








        #region Error Handling Helper Methods
        protected virtual bool SetTableError(
            IntPtr pVtab,
            string error
            )
        {
            try
            {
                SQLiteLog.LogMessage(SQLiteErrorCode.Error,
                    String.Format(CultureInfo.CurrentCulture,
                    "Virtual table error: {0}", error)); /* throw */
            }
            catch
            {
                // do nothing.
            }

            if (pVtab == IntPtr.Zero)
                return false;

            int offset = IntPtr.Size + sizeof(int);
            IntPtr pError = SQLiteMarshal.ReadIntPtr(pVtab, offset);

            if (pError != IntPtr.Zero)