--*/
+#include "pal/dbgmsg.h"
+SET_DEFAULT_DEBUG_CHANNEL(THREAD); // some headers have code with asserts, so do this first
+
#include "pal/corunix.hpp"
#include "pal/context.h"
#include "pal/thread.hpp"
#include "procprivate.hpp"
#include "pal/process.h"
#include "pal/module.h"
-#include "pal/dbgmsg.h"
#include "pal/environ.h"
#include "pal/init.h"
/* ------------------- Definitions ------------------------------*/
-SET_DEFAULT_DEBUG_CHANNEL(THREAD);
// The default stack size of a newly created thread (currently 256KB)
// when the dwStackSize parameter of PAL_CreateThread()