diff cinst/nssstore_win.c @ 329:b1059360a0c7

Debugprintf with output debug string on windows. Makes debugging with redirectred input easier
author Andre Heinecke <aheinecke@intevation.de>
date Tue, 08 Apr 2014 14:52:31 +0000
parents eff8e7ce4dae
children 1e6d1eab8395
line wrap: on
line diff
--- a/cinst/nssstore_win.c	Tue Apr 08 14:50:31 2014 +0000
+++ b/cinst/nssstore_win.c	Tue Apr 08 14:52:31 2014 +0000
@@ -9,6 +9,7 @@
 #include <strsafe.h>
 #include <stdbool.h>
 #include <userenv.h>
+#include <io.h>
 
 #include "logging.h"
 #include "util.h"
@@ -20,12 +21,11 @@
 #define PRINTLASTERROR(msg) \
   char *my_error = getLastErrorMsg(); \
       if (my_error) { \
-        DEBUGMSG(msg " :"); \
-        DEBUGMSG(my_error); \
+        DEBUGPRINTF(msg " : %s\n", my_error); \
         ERRORPRINTF(msg" : %s\n", my_error); \
         free (my_error); \
       } \
-  DEBUGMSG ("Failed to get error information\n");
+  DEBUGPRINTF ("Failed to get error information\n");
 
 /**@brief Write strv of instructions to a handle
 *

http://wald.intevation.org/projects/trustbridge/