X-Git-Url: https://git.novaco.in/?a=blobdiff_plain;f=src%2Futil.h;h=7fd224cbe7cd3435bc701e6e06eff34b648e87be;hb=adce862c2795142a5f56933584abffdbe3599472;hp=1e4ceb2468717106e64957a4e33a9b9de7cefb45;hpb=865ed8a1e5c587468a40756d46bcbc1c5a12bb06;p=novacoin.git diff --git a/src/util.h b/src/util.h index 1e4ceb2..7fd224c 100644 --- a/src/util.h +++ b/src/util.h @@ -65,7 +65,7 @@ typedef unsigned long long uint64; #endif // This is needed because the foreach macro can't get over the comma in pair -#define PAIRTYPE(t1, t2) pair +#define PAIRTYPE(t1, t2) std::pair // Used to bypass the rule against non-const reference to temporary // where it makes sense with wrappers such as CFlatData or CTxDB @@ -140,8 +140,7 @@ inline int myclosesocket(SOCKET& hSocket) return ret; } #define closesocket(s) myclosesocket(s) - -#ifndef GUI +#if !defined(QT_GUI) && !defined(GUI) inline const char* _(const char* psz) { return psz; @@ -156,7 +155,6 @@ inline const char* _(const char* psz) - extern std::map mapArgs; extern std::map > mapMultiArgs; extern bool fDebug; @@ -177,8 +175,8 @@ void RandAddSeed(); void RandAddSeedPerfmon(); int OutputDebugStringF(const char* pszFormat, ...); int my_snprintf(char* buffer, size_t limit, const char* format, ...); -std::string strprintf(const char* format, ...); -bool error(const char* format, ...); +std::string strprintf(const std::string &format, ...); +bool error(const std::string &format, ...); void LogException(std::exception* pex, const char* pszThread); void PrintException(std::exception* pex, const char* pszThread); void PrintExceptionContinue(std::exception* pex, const char* pszThread);