aboutsummaryrefslogtreecommitdiffstats
path: root/src/debug.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2015-08-24 13:03:20 +0000
committerWerner Koch <[email protected]>2015-08-24 13:03:20 +0000
commitdf098d6a437109c57516db75addf3764a6dfda81 (patch)
tree14dcbc874682bb4fd2e272c5591adfc6811f5f74 /src/debug.c
parentAdd an export secret key feature. (diff)
downloadgpgme-df098d6a437109c57516db75addf3764a6dfda81.tar.gz
gpgme-df098d6a437109c57516db75addf3764a6dfda81.zip
w32: Print the installation directory in debug mode.
* src/debug.c (debug_init) [W32]: Show libgpgme installation dir. -- I expect that gpgme will be distributed by applications and thus it will be helpful to see in the debug log which gpgme is actually used. Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to '')
-rw-r--r--src/debug.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/debug.c b/src/debug.c
index 292db555..1dd37234 100644
--- a/src/debug.c
+++ b/src/debug.c
@@ -46,6 +46,7 @@
#include "util.h"
#include "ath.h"
#include "sema.h"
+#include "sys-util.h"
#include "debug.h"
@@ -207,7 +208,16 @@ debug_init (void)
UNLOCK (debug_lock);
if (debug_level > 0)
- _gpgme_debug (DEBUG_INIT, "gpgme_debug: level=%d\n", debug_level);
+ {
+ _gpgme_debug (DEBUG_INIT, "gpgme_debug: level=%d\n", debug_level);
+#ifdef HAVE_W32_SYSTEM
+ {
+ const char *name = _gpgme_get_inst_dir ();
+ _gpgme_debug (DEBUG_INIT, "gpgme_debug: gpgme='%s'\n",
+ name? name: "?");
+ }
+#endif
+ }
}