diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2010-01-21 07:46:29 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2010-01-21 07:46:29 +0000 |
commit | 80ea2c6808e3820773e774d3bca1233bcc9aa87f (patch) | |
tree | 15da0198eb7afa35a70e4008f5e753bed5209245 /src | |
parent | 768c0e3d28e03ba93f5839de5980be8f0dad4d6f (diff) |
show more verbose debug messages when checking gpg.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2441 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 17 |
1 files changed, 14 insertions, 3 deletions
@@ -822,8 +822,19 @@ static void idle_function_for_gpgme(void) static void check_gpg(void) { #if USE_GPGME - if (gpgme_check_version("0.4.5") && - !gpgme_engine_check_version(GPGME_PROTOCOL_OpenPGP)) { + const gchar *version; + gpgme_error_t err = 0; + + version = gpgme_check_version("1.0.0"); + if (version) { + debug_print("GPGME Version: %s\n", version); + err = gpgme_engine_check_version(GPGME_PROTOCOL_OpenPGP); + if (err) + debug_print("gpgme_engine_check_version: %s\n", + gpgme_strerror(err)); + } + + if (version && !err) { /* Also does some gpgme init */ gpgme_engine_info_t engineInfo; @@ -835,7 +846,7 @@ static void check_gpg(void) if (!gpgme_get_engine_info(&engineInfo)) { while (engineInfo) { - debug_print("GpgME Protocol: %s\n Version: %s\n", + debug_print("GPGME Protocol: %s\n Version: %s\n", gpgme_get_protocol_name (engineInfo->protocol), engineInfo->version ? |