Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Correct vtable related maximum memory allocation calculation. Also, always use a lock statement for better portability to the .NET Compact Framework. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | virtualTables |
Files: | files | file ages | folders |
SHA1: |
33eaa984509b50c579f1fc45978e7735 |
User & Date: | mistachkin 2013-06-21 18:13:50.149 |
Context
2013-06-21
| ||
21:01 | Fix vtshim error message handling. Adjust the data-1.28 test to account for the new SQLite3 constructor parameters. Fix delegate declaration for the xFilter method. check-in: ee4c57e435 user: mistachkin tags: virtualTables | |
18:13 | Correct vtable related maximum memory allocation calculation. Also, always use a lock statement for better portability to the .NET Compact Framework. check-in: 33eaa98450 user: mistachkin tags: virtualTables | |
07:23 | Remove unused GetNativeModule method. check-in: e550e1282e user: mistachkin tags: virtualTables | |
Changes
Changes to System.Data.SQLite/SQLiteModule.cs.
1 2 3 4 5 6 7 8 9 10 11 12 | /******************************************************** * ADO.NET 2.0 Data Provider for SQLite Version 3.X * Written by Joe Mistachkin (joe@mistachkin.com) * * Released to the public domain, use at your own risk! ********************************************************/ using System.Collections.Generic; using System.Globalization; using System.Runtime.InteropServices; using System.Text; | < < < < | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | /******************************************************** * ADO.NET 2.0 Data Provider for SQLite Version 3.X * Written by Joe Mistachkin (joe@mistachkin.com) * * Released to the public domain, use at your own risk! ********************************************************/ using System.Collections.Generic; using System.Globalization; using System.Runtime.InteropServices; using System.Text; namespace System.Data.SQLite { #region SQLiteContext Helper Class public sealed class SQLiteContext { #region Private Data private IntPtr pContext; |
︙ | ︙ | |||
1344 1345 1346 1347 1348 1349 1350 | /////////////////////////////////////////////////////////////////////////// #region SQLiteMemory Static Class internal static class SQLiteMemory { #region Private Data #if TRACK_MEMORY_BYTES | < < | 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 | /////////////////////////////////////////////////////////////////////////// #region SQLiteMemory Static Class internal static class SQLiteMemory { #region Private Data #if TRACK_MEMORY_BYTES private static object syncRoot = new object(); /////////////////////////////////////////////////////////////////////// private static int bytesAllocated; private static int maximumBytesAllocated; #endif #endregion |
︙ | ︙ | |||
1369 1370 1371 1372 1373 1374 1375 | #if TRACK_MEMORY_BYTES if (pMemory != IntPtr.Zero) { int blockSize = Size(pMemory); if (blockSize > 0) { | < < < < > > | < | 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 | #if TRACK_MEMORY_BYTES if (pMemory != IntPtr.Zero) { int blockSize = Size(pMemory); if (blockSize > 0) { lock (syncRoot) { bytesAllocated += blockSize; if (bytesAllocated > maximumBytesAllocated) maximumBytesAllocated = bytesAllocated; } } } #endif return pMemory; } |
︙ | ︙ | |||
1408 1409 1410 1411 1412 1413 1414 | #if TRACK_MEMORY_BYTES if (pMemory != IntPtr.Zero) { int blockSize = Size(pMemory); if (blockSize > 0) { | < < < < | 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 | #if TRACK_MEMORY_BYTES if (pMemory != IntPtr.Zero) { int blockSize = Size(pMemory); if (blockSize > 0) { lock (syncRoot) { bytesAllocated -= blockSize; } } } #endif UnsafeNativeMethods.sqlite3_free(pMemory); } #endregion |
︙ | ︙ |