* win32-low.c (LOG): Delete.
authorPedro Alves <palves@redhat.com>
Thu, 26 Nov 2009 22:16:29 +0000 (22:16 +0000)
committerPedro Alves <palves@redhat.com>
Thu, 26 Nov 2009 22:16:29 +0000 (22:16 +0000)
(OUTMSG): Output to stderr.
(OUTMSG2): Conditionalize on `debug_threads' variable, instead of
on compile time LOG macro.
(win32_wait): Fix debug output.

gdb/gdbserver/ChangeLog
gdb/gdbserver/win32-low.c

index 542e9a9aa6fa02364cac86632c6cf32cb1dd2e91..64619ee2a53b5df16b9923c384a3293b753a064e 100644 (file)
@@ -1,3 +1,11 @@
+2009-11-26  Pedro Alves  <pedro@codesourcery.com>
+
+       * win32-low.c (LOG): Delete.
+       (OUTMSG): Output to stderr.
+       (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
+       on compile time LOG macro.
+       (win32_wait): Fix debug output.
+
 2009-11-26  Pedro Alves  <pedro@codesourcery.com>
 
        * win32-low.c (win32_add_one_solib): If the dll name is
index ff46b2de28293df552f0380150ea9a310e301418..3b9ae591329dc157d8189b24b2dfdd581cb25e67 100644 (file)
 #include <sys/cygwin.h>
 #endif
 
-#define LOG 0
-
-#define OUTMSG(X) do { printf X; fflush (stdout); } while (0)
-#if LOG
-#define OUTMSG2(X) do { printf X; fflush (stdout); } while (0)
-#else
-#define OUTMSG2(X) do ; while (0)
-#endif
+#define OUTMSG(X) do { printf X; fflush (stderr); } while (0)
+
+#define OUTMSG2(X) \
+  do                                           \
+    {                                          \
+      if (debug_threads)                       \
+       {                                       \
+         printf X;                             \
+         fflush (stderr);                      \
+       }                                       \
+    } while (0)
 
 #ifndef _T
 #define _T(x) TEXT (x)
@@ -1586,7 +1589,7 @@ win32_wait (ptid_t ptid, struct target_waitstatus *ourstatus, int options)
        case TARGET_WAITKIND_STOPPED:
        case TARGET_WAITKIND_LOADED:
          OUTMSG2 (("Child Stopped with signal = %d \n",
-                   our_status.value.sig));
+                   ourstatus->value.sig));
 
          child_fetch_inferior_registers (-1);
 
This page took 0.030048 seconds and 4 git commands to generate.