Hi,

I've read that there is a compile option to unable connexion being
thread-safe : http://www.sqlite.org/compile.html#threadsafe

I guess also there could be problems if you have a not commited
transaction pending while you are using another for write access, and/or a
previous statement not reseted (sqlite3_reset) or not finalized...
See http://www.sqlite.org/lang_transaction.html and
http://www.sqlite.org/lockingv3.html

Vincnet


>
> Good day!
>
> I would just like to ask if SQLite transactions might result to a
> deadlock?
> Because I have this type of code snippet:
>
> [code]
> printf( "before sqlite3_prepare\n" );
> sqlite3_prepare( ... );
> printf( "after sqlite3_prepare" );
> [/code]
>
> Then sometimes, when my program is executing, the result will be just:
>
> [quote]
> before sqlite3_prepare
> [/quote]
>
> So I was wondering why the program suddenly stops at that point. It just
> hanged there and it seems waiting for something I do not know. Is it
> possible that there is some kind of a deadlock happening in the
> sqlite3_prepare api?
>
> Additional information: Several processes and threads call at the function
> where this code is found. The processes/threads were created through
> fork()
> and pthread_create() functions.
>
> Hope you can help me.
>
> Thank you and God bless!
> --
> View this message in context:
> http://www.nabble.com/Deadlock-on-SQLite-tp20377453p20377453.html
> Sent from the SQLite mailing list archive at Nabble.com.
>
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
>



_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to