Commit 7ffa6f4d authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

Always define UT_DBG_ABORT in innodb/xtradb, also on Windows. This will avoid...

Always define UT_DBG_ABORT in innodb/xtradb, also on Windows. This will avoid endless hangs inside ut_dgb_stop_thread
parent cff7a986
...@@ -55,11 +55,9 @@ ut_dbg_assertion_failed( ...@@ -55,11 +55,9 @@ ut_dbg_assertion_failed(
ulint line) /*!< in: line number of the assertion */ ulint line) /*!< in: line number of the assertion */
UNIV_COLD __attribute__((nonnull(2))); UNIV_COLD __attribute__((nonnull(2)));
#if defined(__WIN__) || defined(__INTEL_COMPILER)
# undef UT_DBG_USE_ABORT #define UT_DBG_USE_ABORT
#elif defined(__GNUC__) && (__GNUC__ > 2)
# define UT_DBG_USE_ABORT
#endif
#ifndef UT_DBG_USE_ABORT #ifndef UT_DBG_USE_ABORT
/** A null pointer that will be dereferenced to trigger a memory trap */ /** A null pointer that will be dereferenced to trigger a memory trap */
...@@ -83,7 +81,11 @@ ut_dbg_stop_thread( ...@@ -83,7 +81,11 @@ ut_dbg_stop_thread(
#ifdef UT_DBG_USE_ABORT #ifdef UT_DBG_USE_ABORT
/** Abort the execution. */ /** Abort the execution. */
#ifdef _WIN32
# define UT_DBG_PANIC __debugbreak()
#else
# define UT_DBG_PANIC abort() # define UT_DBG_PANIC abort()
#endif
/** Stop threads (null operation) */ /** Stop threads (null operation) */
# define UT_DBG_STOP do {} while (0) # define UT_DBG_STOP do {} while (0)
#else /* UT_DBG_USE_ABORT */ #else /* UT_DBG_USE_ABORT */
......
...@@ -55,11 +55,9 @@ ut_dbg_assertion_failed( ...@@ -55,11 +55,9 @@ ut_dbg_assertion_failed(
ulint line) /*!< in: line number of the assertion */ ulint line) /*!< in: line number of the assertion */
UNIV_COLD __attribute__((nonnull(2))); UNIV_COLD __attribute__((nonnull(2)));
#if defined(__WIN__) || defined(__INTEL_COMPILER)
# undef UT_DBG_USE_ABORT #define UT_DBG_USE_ABORT
#elif defined(__GNUC__) && (__GNUC__ > 2)
# define UT_DBG_USE_ABORT
#endif
#ifndef UT_DBG_USE_ABORT #ifndef UT_DBG_USE_ABORT
/** A null pointer that will be dereferenced to trigger a memory trap */ /** A null pointer that will be dereferenced to trigger a memory trap */
...@@ -83,7 +81,11 @@ ut_dbg_stop_thread( ...@@ -83,7 +81,11 @@ ut_dbg_stop_thread(
#ifdef UT_DBG_USE_ABORT #ifdef UT_DBG_USE_ABORT
/** Abort the execution. */ /** Abort the execution. */
#ifdef _WIN32
# define UT_DBG_PANIC __debugbreak()
#else
# define UT_DBG_PANIC abort() # define UT_DBG_PANIC abort()
#endif
/** Stop threads (null operation) */ /** Stop threads (null operation) */
# define UT_DBG_STOP do {} while (0) # define UT_DBG_STOP do {} while (0)
#else /* UT_DBG_USE_ABORT */ #else /* UT_DBG_USE_ABORT */
......
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