|Title:||SQLiteFactory raises CallbackOnCollectedDelegate|
|Last Modified:||2011-10-20 07:23:26|
|Version Found In:||22.214.171.124|
Every time I access an instance of System.Data.SQLite.SQLiteFactory, I get this exception when in debug-mode. Can I safely ignore it? Or what can I do to prevent this error?
mistachkin added on 2011-10-17 14:09:33 UTC:
anonymous added on 2011-10-17 17:34:16 UTC:
I only see the error when I set the IDE to break on ALL thrown exceptions.
The code looks like this:
Private Class Sql
Private Factory As New System.Data.SQLite.SQLiteFactory()
Public Function Connect() As Boolean
Dim Conn as DbConnection = Fact.CreateConnection()
It seems to be related to threads. The first thread has no problems creating a new instance of the class above, but the second thread will complain with:
A callback was made on a garbage collected delegate of type 'System.Data.SQLite!System.Data.SQLite.SQLiteLogCallback::Invoke'. This may cause application crashes, corruption and data loss. When passing delegates to unmanaged code, they must be kept alive by the managed application until it is guaranteed that they will never be called.
mistachkin added on 2011-10-18 03:08:39 UTC:
anonymous added on 2011-10-19 16:58:20 UTC:
anonymous added on 2011-10-19 17:15:50 UTC: