diff options
author | unknown <monty@hundin.mysql.fi> | 2001-09-12 23:53:31 +0300 |
---|---|---|
committer | unknown <monty@hundin.mysql.fi> | 2001-09-12 23:53:31 +0300 |
commit | 76989cf55c016a9d8619f582f753444241a4d934 (patch) | |
tree | 51a09b9e3466647e4386ab24f3c9aa89ff7a93b9 /libmysql/dll.c | |
parent | a53e8ea0ac4f7d53297b7942febf04e02d8c3b54 (diff) | |
download | mariadb-git-76989cf55c016a9d8619f582f753444241a4d934.tar.gz |
OS2 patch
Docs/manual.texi:
Updated section of how to change the socket file.
Changelog for 3.23.43
include/merge.h:
Fixed typo
include/my_pthread.h:
Fixed bug for WIN32
include/myisam.h:
Fixed typo
include/nisam.h:
Fixed typo
sql/handler.h:
Fixed typo
sql/sql_table.cc:
Fixed typo
sql/unireg.cc:
F
Diffstat (limited to 'libmysql/dll.c')
-rw-r--r-- | libmysql/dll.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/libmysql/dll.c b/libmysql/dll.c index 4c952c5889e..d1a23794025 100644 --- a/libmysql/dll.c +++ b/libmysql/dll.c @@ -110,3 +110,25 @@ int _export FAR PASCAL libmain(HANDLE hModule,short cbHeapSize, } #endif + +#ifdef OS2 + +// +// This function is called automatically by _DLL_InitTerm +// Every dll runtime enviroment is not tz enabled, so tzset() +// must be called to enable TZ handling +// Also timezone is fixed. +// +extern "C" unsigned long _System DllMain(unsigned long modhandle, + unsigned long flag) +{ + if (flag == 0) { + tzset(); // Set tzname + time_t currentTime = time(NULL); + struct tm *ts = localtime(¤tTime); + if (ts->tm_isdst > 0) + _timezone -= 3600; + } +} + +#endif |