aboutsummaryrefslogtreecommitdiff
path: root/src/util_ct.h
diff options
context:
space:
mode:
authorDavid Timber <mieabby@gmail.com>2020-08-17 18:16:49 +0930
committerDavid Timber <mieabby@gmail.com>2020-08-17 18:35:31 +0930
commit7bd3eb3b1ad4209ac4cf4b46f849213d46bc33aa (patch)
tree0e7a16fb3d36ada8a2a494f8dc063e8b67350d58 /src/util_ct.h
parentd7cc11191dfd3fead5e596fcbc24f40d1317819e (diff)
Employ pthsem ...
* Use uint8_t array for hardcoded binary data * Add proone-ipaddr-arr to hardcode DoT servers * Convert X509 data * Brought back M68k and ARC archs just in case * Add CLOCK_REALTIME in prne_mbedtls_entropy_proc_src_f for more entropy * Remove installation of signal handlers. Use sigwait() instead * Bugfix: prne_rnd_anum_str() returned null characters * Add prne_dbgpf() and prne_dbgperr() * prne_assert(): put errno into a register so it's visible in the core dump
Diffstat (limited to 'src/util_ct.h')
-rw-r--r--src/util_ct.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/util_ct.h b/src/util_ct.h
index 134ac57..cd21a12 100644
--- a/src/util_ct.h
+++ b/src/util_ct.h
@@ -13,3 +13,11 @@
#if !defined(memzero)
#define memzero(addr, len) memset(addr, 0, len)
#endif
+
+#ifdef PRNE_DEBUG
+#define prne_dbgpf(...) fprintf(stderr, __VA_ARGS__)
+#define prne_dbgperr(str) perror(str)
+#else
+#define prne_dbgpf(fmt, ...)
+#define prne_dbgperr(str)
+#endif