summaryrefslogtreecommitdiff
path: root/src/cryptinit.hpp
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/cryptinit.hpp
parentimproved Makefile (clean now for -j *) (diff)
log class can now easily use errno and gpg_err
Diffstat (limited to 'src/cryptinit.hpp')
-rw-r--r--src/cryptinit.hpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/cryptinit.hpp b/src/cryptinit.hpp
index 80f4e14..e5bbc08 100644
--- a/src/cryptinit.hpp
+++ b/src/cryptinit.hpp
@@ -92,18 +92,14 @@ bool initLibGCrypt()
gcry_error_t err = gcry_control (GCRYCTL_DISABLE_SECMEM, 0);
if( err ) {
- char buf[STERROR_TEXT_MAX];
- buf[0] = 0;
- std::cout << "initLibGCrypt: Failed to disable secure memory: " << gpg_strerror_r(err, buf, STERROR_TEXT_MAX) << std::endl;
+ std::cout << "initLibGCrypt: Failed to disable secure memory: " << LogGpgError(err) << std::endl;
return false;
}
// Tell Libgcrypt that initialization has completed.
err = gcry_control(GCRYCTL_INITIALIZATION_FINISHED);
if( err ) {
- char buf[STERROR_TEXT_MAX];
- buf[0] = 0;
- std::cout << "initLibGCrypt: Failed to finish initialization: " << gpg_strerror_r(err, buf, STERROR_TEXT_MAX) << std::endl;
+ std::cout << "initLibGCrypt: Failed to finish initialization: " << LogGpgError(err) << std::endl;
return false;
}