From d6dfa9a8ab625eb854bd0b0520b3e47b76f71bac Mon Sep 17 00:00:00 2001 From: Pieter Wuille Date: Fri, 25 May 2012 16:03:10 +0200 Subject: [PATCH] fix logging --- netbase.cpp | 2 ++ util.h | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/netbase.cpp b/netbase.cpp index e91a252..45074bf 100644 --- a/netbase.cpp +++ b/netbase.cpp @@ -13,6 +13,8 @@ #include "strlcpy.h" #include // for to_lower() +#define printf my_printf + using namespace std; // Settings diff --git a/util.h b/util.h index 3eedd75..fbcbd1f 100644 --- a/util.h +++ b/util.h @@ -90,10 +90,14 @@ std::string static inline strprintf(const std::string &format, ...) { return ret; } -bool static inline error(std::string err) { +bool static inline error(std::string err, ...) { return false; } +bool static inline my_printf(std::string err, ...) { + return true; +} + std::vector DecodeBase32(const char* p, bool* pfInvalid = NULL); std::string DecodeBase32(const std::string& str); std::string EncodeBase32(const unsigned char* pch, size_t len);