summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mnogosearch.org>2013-01-29 19:15:22 +0400
committerAlexander Barkov <bar@mnogosearch.org>2013-01-29 19:15:22 +0400
commitab76cdb236fe35df9e3b0ce8e35bf1b16982715c (patch)
treec0f6cac795db5d8ad7838af528d1d27d380b82db /storage
parentd78d3d4fc9cb6d4e28881721a9f5d90d32280b35 (diff)
downloadmariadb-git-ab76cdb236fe35df9e3b0ce8e35bf1b16982715c.tar.gz
Compilation failed on Debian 32-bit.
Fixing DWORD definition once again as "unsigned long", which is the way how MS defines it. modified: @ storage/connect/os.h Changing DWORD defitition @ storage/connect/tabodbc.cpp Moving "#define NODW" to proper place.
Diffstat (limited to 'storage')
-rw-r--r--storage/connect/os.h8
-rw-r--r--storage/connect/tabodbc.cpp2
2 files changed, 8 insertions, 2 deletions
diff --git a/storage/connect/os.h b/storage/connect/os.h
index 90e8eea1141..52eed14df0f 100644
--- a/storage/connect/os.h
+++ b/storage/connect/os.h
@@ -28,7 +28,13 @@ typedef char *LPTSTR;
typedef char *PSZ;
typedef int INT;
#if !defined(NODW)
-typedef unsigned int DWORD;
+/*
+ sqltypes.h from unixODBC incorrectly defines
+ DWORD as "unsigned int" instead of "unsigned long" on 64-bit platforms.
+ Add "#define NODW" into all files including this file that include
+ sqltypes.h (through sql.h or sqlext.h).
+*/
+typedef unsigned long DWORD;
#endif /* !NODW */
#undef HANDLE
typedef int HANDLE;
diff --git a/storage/connect/tabodbc.cpp b/storage/connect/tabodbc.cpp
index caec386d683..0b45691bcc3 100644
--- a/storage/connect/tabodbc.cpp
+++ b/storage/connect/tabodbc.cpp
@@ -46,12 +46,12 @@
#else
#if defined(UNIX)
#include <errno.h>
+#define NODW
#include "osutil.h"
#else
#include <io.h>
#endif
#include <fcntl.h>
-#define NODW
#endif
/***********************************************************************/