-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 05/15/2011 11:14 AM, Steven Parkes wrote:
>> Isn't that exactly what NOMUTEX does?
> 
> The docs (http://www.sqlite.org/threadsafe.html) say 
> 
>   The SQLITE_OPEN_NOMUTEX flag causes the database connection to be in the 
> multi-thread mode and
>   the SQLITE_OPEN_FULLMUTEX flag causes the connection to be in serialized 
> mode.
> 
> Is this wrong?

It is misleading but the documentation is consistent.  See
http://www.sqlite.org/threadsafe.html

Multi-thread mode means that *you* have to ensure it is not used in more
than one thread concurrently.  ie mutexes that normally ensure SQLite is
safe to use in multiple threads concurrently are not used and ensuring that
multi-thread safety is entirely up to the caller.

Which is why you'll generally want normal/serialized/fullmutex since SQLite
will then take complete care of itself in a multi-threaded environment.  If
you disable that then you will have to ensure you have paid the same
attention to detail, design and testing and any bug reports would need to
eliminate your code taking over responsibility for thread safety as the issue.

Roger
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAk3QUeEACgkQmOOfHg372QR59QCeMJdal/su37np9x+me0oRYjCB
uwUAoKzkOH+1SUK1YghzBA2C+UAlSKtD
=xBUF
-----END PGP SIGNATURE-----
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to