At 15:31 17/12/2002 +0100, Ralf Hupfer wrote:
Hi,
As you stated, you have to use mysql_thread_start and mysql_thread_end
plus a critical section to protect mysql_real_connect.
At the end of my programs I call my_end.
The commands mysql_thread_init() and mysql_thread_end() are not defined in
the Windows version of the client C API.
Take a look in the source of 4.0.X:
/include/config-win.h
--125--
#ifndef UNDEF_THREAD_HACK
#define THREAD
#endif
/libmysql;libmysql.c
--112--
my_bool STDCALL mysql_thread_init()
{
#ifdef THREAD
return my_thread_init();
#else
return 0;
#endif
}
void STDCALL mysql_thread_end()
{
#ifdef THREAD
my_thread_end();
#endif
}