Commit ca28d5fc authored by Michael Widenius's avatar Michael Widenius

automatic merge

parents c01ec9d5 398f754b
......@@ -49,7 +49,7 @@
TODO : Verify if FreeBSD & AIX stores ISO 10646 in wchar_t. */
#if !defined(__NetBSD__) && !defined(__sun) \
&& !(defined(__APPLE__) && defined(__MACH__)) \
&& !defined(__FreeBSD__) && !defined(_AIX)
&& !defined(__FreeBSD__) && !defined(_AIX) && !defined(__OpenBSD__)
#ifndef __STDC_ISO_10646__
/* 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
......
......@@ -64,7 +64,7 @@ static char sccsid[] = "@(#)unvis.c 8.1 (Berkeley) 6/4/93";
#include "np/vis.h"
#ifdef __weak_alias
__weak_alias(strnunvisx,_strnunvisx)
__weak_alias(strnunvisx,_strnunvisx);
#endif
#if !HAVE_VIS
......
......@@ -77,7 +77,7 @@
#include <stdlib.h>
#ifdef __weak_alias
__weak_alias(strvisx,_strvisx)
__weak_alias(strvisx,_strvisx);
#endif
#if !HAVE_VIS || !HAVE_SVIS
......
......@@ -124,7 +124,7 @@ void my_time_init()
ulonglong my_getcputime()
{
#ifdef HAVE_CLOCK_GETTIME
#ifdef CLOCK_THREAD_CPUTIME_ID
struct timespec tp;
if (clock_gettime(CLOCK_THREAD_CPUTIME_ID, &tp))
return 0;
......
......@@ -7,6 +7,7 @@
*/
#include <my_config.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <errno.h>
#include <poll.h>
......
......@@ -2678,6 +2678,7 @@ static void init_signals(void)
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))
{
sa.sa_flags = SA_RESETHAND | SA_NODEFER;
......@@ -2700,6 +2701,7 @@ static void init_signals(void)
sigaction(SIGILL, &sa, NULL);
sigaction(SIGFPE, &sa, NULL);
}
#endif
#ifdef HAVE_GETRLIMIT
if (test_flags & TEST_CORE_ON_SIGNAL)
......
......@@ -2203,7 +2203,7 @@ static int check_func_bool(THD *thd, struct st_mysql_sys_var *var,
{
if (value->val_int(value, &tmp) < 0)
goto err;
if (tmp > 1)
if (tmp != 0 && tmp != 1)
{
llstr(tmp, buff);
strvalue= buff;
......@@ -2211,7 +2211,7 @@ static int check_func_bool(THD *thd, struct st_mysql_sys_var *var,
}
result= (int) tmp;
}
*(my_bool *) save= -result;
*(my_bool *) save= result ? 1 : 0;
return 0;
err:
my_error(ER_WRONG_VALUE_FOR_VAR, MYF(0), var->name, strvalue);
......@@ -2392,7 +2392,7 @@ err:
static void update_func_bool(THD *thd, struct st_mysql_sys_var *var,
void *tgt, const void *save)
{
*(my_bool *) tgt= *(my_bool *) save ? TRUE : FALSE;
*(my_bool *) tgt= *(my_bool *) save ? 1 : 0;
}
......
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