YKCS11: Change DBG to print to stderr.
This commit is contained in:
+5
-5
@@ -4,15 +4,15 @@
|
||||
#define YKCS11_DBG 1 // General debug, must be either 1 or 0
|
||||
#define YKCS11_DINOUT 1 // Function in/out debug, must be either 1 or 0
|
||||
|
||||
#define D(x) do { \
|
||||
printf ("debug: %s:%d (%s): ", __FILE__, __LINE__, __FUNCTION__); \
|
||||
printf x; \
|
||||
printf ("\n"); \
|
||||
#define D(x...) do { \
|
||||
fprintf (stderr, "debug: %s:%d (%s): ", __FILE__, __LINE__, __FUNCTION__); \
|
||||
fprintf (stderr, x); \
|
||||
fprintf (stderr, "\n"); \
|
||||
} while (0)
|
||||
|
||||
#if YKCS11_DBG
|
||||
#include <stdio.h>
|
||||
#define DBG(x) D(x);
|
||||
#define DBG(x...) D(x);
|
||||
#else
|
||||
#define DBG(x)
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user