Darwin: Undefine NDEBUG for assert.h
For some reason, having NDEBUG defined when #including assert.h causes assert() to hang us. This should just cause assert() to nop (it is #defined to be (void)0 in that case).
This commit is contained in:
parent
a8e35ebf93
commit
f5e5b255d1
|
@ -56,10 +56,9 @@
|
|||
===========================================================================
|
||||
*/
|
||||
|
||||
// Including this crashes us... why?
|
||||
// #ifdef HAVE_XORG_CONFIG_H
|
||||
// #include <xorg-config.h>
|
||||
// #endif
|
||||
#ifdef HAVE_XORG_CONFIG_H
|
||||
#include <xorg-config.h>
|
||||
#endif
|
||||
|
||||
// Define this to get a diagnostic output to stderr which is helpful
|
||||
// in determining how the X server is interpreting the Darwin keymap.
|
||||
|
@ -74,7 +73,15 @@
|
|||
#include <architecture/byte_order.h> // For the NXSwap*
|
||||
#include "darwin.h"
|
||||
#include "darwinKeyboard.h"
|
||||
|
||||
#ifdef NDEBUG
|
||||
#undef NDEBUG
|
||||
#include <assert.h>
|
||||
#define NDEBUG 1
|
||||
#else
|
||||
#include <assert.h>
|
||||
#endif
|
||||
|
||||
#define AltMask Mod1Mask
|
||||
#define MetaMask Mod2Mask
|
||||
#define FunctionMask Mod3Mask
|
||||
|
|
|
@ -27,10 +27,9 @@
|
|||
* use or other dealings in this Software without prior written authorization.
|
||||
*/
|
||||
|
||||
// Including this crashes us... why?
|
||||
// #ifdef HAVE_XORG_CONFIG_H
|
||||
// #include <xorg-config.h>
|
||||
// #endif
|
||||
#ifdef HAVE_XORG_CONFIG_H
|
||||
#include <xorg-config.h>
|
||||
#endif
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <unistd.h>
|
||||
|
@ -40,7 +39,14 @@
|
|||
#include "quartz.h"
|
||||
#include "opaque.h"
|
||||
#include "micmap.h"
|
||||
|
||||
#ifdef NDEBUG
|
||||
#undef NDEBUG
|
||||
#include <assert.h>
|
||||
#define NDEBUG 1
|
||||
#else
|
||||
#include <assert.h>
|
||||
#endif
|
||||
|
||||
char **envpGlobal; // argcGlobal and argvGlobal
|
||||
// are from dix/globals.c
|
||||
|
|
Loading…
Reference in New Issue
Block a user