summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorunknown <serg@serg.mylan>2005-03-15 18:31:56 +0100
committerunknown <serg@serg.mylan>2005-03-15 18:31:56 +0100
commitc286b08605c567c95745bc90e8fc401e05c2fa5f (patch)
tree044bbd67dc86a3d7763ae18f9c8015e344b2928a /include
parentd4cf05f6d30ce30c557a91140af289f9f198d5d7 (diff)
downloadmariadb-git-c286b08605c567c95745bc90e8fc401e05c2fa5f.tar.gz
include/my_global.h
define _XOPEN_SOURCE=500 for solaris include/my_sys.h remove a cast include/my_global.h: define _XOPEN_SOURCE=500 for solaris include/my_sys.h: remove a cast
Diffstat (limited to 'include')
-rw-r--r--include/my_global.h15
-rw-r--r--include/my_sys.h2
2 files changed, 16 insertions, 1 deletions
diff --git a/include/my_global.h b/include/my_global.h
index e9470ac48aa..e78ec21523d 100644
--- a/include/my_global.h
+++ b/include/my_global.h
@@ -120,6 +120,21 @@
#define __STDC_EXT__ 1 /* To get large file support on hpux */
#endif
+/*
+ Solaris include file <sys/feature_tests.h> refers to X/Open document
+
+ System Interfaces and Headers, Issue 5
+
+ saying we should define _XOPEN_SOURCE=500 to get POSIX.1c prototypes
+ but apparently other systems (namely FreeBSD) don't agree.
+ Furthermore X/Open has since 2004 "System Interfaces, Issue 6"
+ that dictates _XOPEN_SOURCE=600, but Solaris checks for 500.
+ So, let's define 500 for solaris only.
+*/
+#ifdef __sun__
+#define _XOPEN_SOURCE 500
+#endif
+
#if defined(THREAD) && !defined(__WIN__) && !defined(OS2)
#ifndef _POSIX_PTHREAD_SEMANTICS
#define _POSIX_PTHREAD_SEMANTICS /* We want posix threads */
diff --git a/include/my_sys.h b/include/my_sys.h
index ce785b58da4..afd2803b75d 100644
--- a/include/my_sys.h
+++ b/include/my_sys.h
@@ -812,7 +812,7 @@ my_bool my_gethwaddr(uchar *to);
/* qnx ? */
#define my_getpagesize() 8192
#endif
-#define my_munmap(a,b) munmap((char*)(a),(b))
+#define my_munmap(a,b) munmap((a),(b))
#else
/* not a complete set of mmap() flags, but only those that nesessary */