Commit 3dc35ee4 authored by Michael Widenius's avatar Michael Widenius

Compatibility fixes by U Orsini

parent 474ee1ee
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
TODO : Verify if FreeBSD & AIX stores ISO 10646 in wchar_t. */ TODO : Verify if FreeBSD & AIX stores ISO 10646 in wchar_t. */
#if !defined(__NetBSD__) && !defined(__sun) \ #if !defined(__NetBSD__) && !defined(__sun) \
&& !(defined(__APPLE__) && defined(__MACH__)) \ && !(defined(__APPLE__) && defined(__MACH__)) \
&& !defined(__FreeBSD__) && !defined(_AIX) && !defined(__FreeBSD__) && !defined(_AIX) && !defined(__OpenBSD__)
#ifndef __STDC_ISO_10646__ #ifndef __STDC_ISO_10646__
/* In many places it is assumed that the first 127 code points are ASCII /* In many places it is assumed that the first 127 code points are ASCII
* compatible, so ensure wchar_t indeed does ISO 10646 and not some other * compatible, so ensure wchar_t indeed does ISO 10646 and not some other
......
...@@ -64,7 +64,7 @@ static char sccsid[] = "@(#)unvis.c 8.1 (Berkeley) 6/4/93"; ...@@ -64,7 +64,7 @@ static char sccsid[] = "@(#)unvis.c 8.1 (Berkeley) 6/4/93";
#include "np/vis.h" #include "np/vis.h"
#ifdef __weak_alias #ifdef __weak_alias
__weak_alias(strnunvisx,_strnunvisx) __weak_alias(strnunvisx,_strnunvisx);
#endif #endif
#if !HAVE_VIS #if !HAVE_VIS
......
...@@ -77,7 +77,7 @@ ...@@ -77,7 +77,7 @@
#include <stdlib.h> #include <stdlib.h>
#ifdef __weak_alias #ifdef __weak_alias
__weak_alias(strvisx,_strvisx) __weak_alias(strvisx,_strvisx);
#endif #endif
#if !HAVE_VIS || !HAVE_SVIS #if !HAVE_VIS || !HAVE_SVIS
......
...@@ -124,7 +124,7 @@ void my_time_init() ...@@ -124,7 +124,7 @@ void my_time_init()
ulonglong my_getcputime() ulonglong my_getcputime()
{ {
#ifdef HAVE_CLOCK_GETTIME #ifdef CLOCK_THREAD_CPUTIME_ID
struct timespec tp; struct timespec tp;
if (clock_gettime(CLOCK_THREAD_CPUTIME_ID, &tp)) if (clock_gettime(CLOCK_THREAD_CPUTIME_ID, &tp))
return 0; return 0;
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
*/ */
#include <my_config.h> #include <my_config.h>
#include <sys/types.h>
#include <netinet/in.h> #include <netinet/in.h>
#include <errno.h> #include <errno.h>
#include <poll.h> #include <poll.h>
......
...@@ -2678,6 +2678,7 @@ static void init_signals(void) ...@@ -2678,6 +2678,7 @@ static void init_signals(void)
my_sigset(THR_SERVER_ALARM,print_signal_warning); // Should never be called! my_sigset(THR_SERVER_ALARM,print_signal_warning); // Should never be called!
#ifdef HAVE_STACKTRACE
if (opt_stack_trace || (test_flags & TEST_CORE_ON_SIGNAL)) if (opt_stack_trace || (test_flags & TEST_CORE_ON_SIGNAL))
{ {
sa.sa_flags = SA_RESETHAND | SA_NODEFER; sa.sa_flags = SA_RESETHAND | SA_NODEFER;
...@@ -2700,6 +2701,7 @@ static void init_signals(void) ...@@ -2700,6 +2701,7 @@ static void init_signals(void)
sigaction(SIGILL, &sa, NULL); sigaction(SIGILL, &sa, NULL);
sigaction(SIGFPE, &sa, NULL); sigaction(SIGFPE, &sa, NULL);
} }
#endif
#ifdef HAVE_GETRLIMIT #ifdef HAVE_GETRLIMIT
if (test_flags & TEST_CORE_ON_SIGNAL) if (test_flags & TEST_CORE_ON_SIGNAL)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment