[unixODBC-dev] [PATCH] Fix for __SQLGetInfo

Richard Kettlewell richard+unixodbc at sfere.greenend.org.uk
Wed Mar 23 17:27:58 GMT 2011


__SQLGetInfo() exits via function_return(), but its callers all expect 
to call this function too.  The effect is that it unlocks the mutex 
earlier than expected, and moreover then releases it a second time 
(possibly after another thread has acquired it).

The effect is intermittent crashes, at least the extremely thread-heavy 
program I am working on.

The attached patch fixes this problem, eliminating the crashes.  I've 
been running my tests against a patched version all day, so I'm pretty 
confident that I've improved the situation l-)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 17962.diff
Type: text/x-patch
Size: 2704 bytes
Desc: not available
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-dev/attachments/20110323/ce5251a8/attachment.bin>

More information about the unixODBC-dev mailing list