summaryrefslogtreecommitdiff
path: root/src/log.h
diff options
context:
space:
mode:
authorChristian Pointner <equinox@anytun.org>2009-01-15 16:28:12 +0000
committerChristian Pointner <equinox@anytun.org>2009-01-15 16:28:12 +0000
commit1c5626cd8a3dd28d7d09e01d6d3b95f49f10e421 (patch)
treee251b16e72d99ea7696d222c24fb13fd13812890 /src/log.h
parentimproved Makefile (clean now for -j *) (diff)
log class can now easily use errno and gpg_err
Diffstat (limited to 'src/log.h')
-rw-r--r--src/log.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/log.h b/src/log.h
index 5c12661..e1f9163 100644
--- a/src/log.h
+++ b/src/log.h
@@ -40,6 +40,31 @@
#include "threadUtils.hpp"
+
+#define STERROR_TEXT_MAX 100
+
+#ifndef NOCRYPT
+#ifndef USE_SSL_CRYPTO
+#include <gcrypt.h>
+
+class LogGpgError
+{
+public:
+ LogGpgError(gcry_error_t e) : err_(e) {};
+ gcry_error_t err_;
+};
+std::ostream& operator<<(std::ostream& stream, LogGpgError const& value);
+#endif
+#endif
+
+class LogErrno
+{
+public:
+ LogErrno(int e) : err_(e) {};
+ int err_;
+};
+std::ostream& operator<<(std::ostream& stream, LogErrno const& value);
+
class Log;
class LogStringBuilder