Commit b6caf69d authored by Simon McVittie's avatar Simon McVittie Committed by Simon McVittie

Fix remaining -Wundef warnings

Vaguely based on a patch from Thomas Zimmermann, but with a different
solution to RECURSIVE_MARSHAL_WRITE_TRACE, and additionally fixing
a build failure that only occurs when targeting Unix without libsystemd,
and another that occurs when targeting Windows.
Signed-off-by: default avatarSimon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: default avatarThomas Zimmermann <tdz@users.sourceforge.net>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=97357
parent 47f14b8e
......@@ -35,6 +35,9 @@
#define PRIx64 "I64x"
#endif
/** turn this on to get deluged in TypeWriter verbose spam */
#define RECURSIVE_MARSHAL_WRITE_TRACE 0
static void
basic_value_zero (DBusBasicValue *value)
{
......
......@@ -2464,7 +2464,7 @@ static void dump_backtrace_for_thread (HANDLE hThread)
sf.AddrFrame.Mode = AddrModeFlat;
sf.AddrPC.Offset = context.Eip;
sf.AddrPC.Mode = AddrModeFlat;
#elif _M_X64
#elif defined(_M_X64)
dwImageType = IMAGE_FILE_MACHINE_AMD64;
sf.AddrPC.Offset = context.Rip;
sf.AddrPC.Mode = AddrModeFlat;
......@@ -2472,7 +2472,7 @@ static void dump_backtrace_for_thread (HANDLE hThread)
sf.AddrFrame.Mode = AddrModeFlat;
sf.AddrStack.Offset = context.Rsp;
sf.AddrStack.Mode = AddrModeFlat;
#elif _M_IA64
#elif defined(_M_IA64)
dwImageType = IMAGE_FILE_MACHINE_IA64;
sf.AddrPC.Offset = context.StIIP;
sf.AddrPC.Mode = AddrModeFlat;
......
......@@ -29,7 +29,7 @@
#include "dbus-protocol.h"
#include <string.h>
#if HAVE_SYSTEMD
#ifdef HAVE_SYSTEMD
#include <systemd/sd-login.h>
#endif
......
......@@ -44,7 +44,7 @@ main (int argc, char **argv)
SetUnhandledExceptionFilter((LPTOP_LEVEL_EXCEPTION_FILTER)&exception_handler);
#endif
#if HAVE_SETRLIMIT
#ifdef HAVE_SETRLIMIT
/* No core dumps please, we know we crashed. */
struct rlimit r = { 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