diff options
Diffstat (limited to 'common')
-rw-r--r-- | common/ChangeLog | 10 | ||||
-rw-r--r-- | common/asshelp.c | 10 | ||||
-rw-r--r-- | common/homedir.c | 6 | ||||
-rw-r--r-- | common/i18n.c | 2 | ||||
-rw-r--r-- | common/util.h | 2 |
5 files changed, 25 insertions, 5 deletions
diff --git a/common/ChangeLog b/common/ChangeLog index 943b9f033..860d3cb69 100644 --- a/common/ChangeLog +++ b/common/ChangeLog @@ -1,3 +1,13 @@ +2008-05-26 Werner Koch <[email protected]> + + * asshelp.c (send_one_option, send_pinentry_environment): use + xfree and xtrystrdup. + + * i18n.c (i18n_switchto_utf8) [USE_SIMPLE_GETTEXT]: Return NULL. + + * homedir.c (gnupg_module_name): Add + GNUPG_MODULE_NAME_CONNECT_AGENT and GNUPG_MODULE_NAME_GPGCONF. + 2008-04-21 Werner Koch <[email protected]> * http.c (http_wait_response) [W32]: Use DuplicateHandle because diff --git a/common/asshelp.c b/common/asshelp.c index 8274d88a7..99da71a22 100644 --- a/common/asshelp.c +++ b/common/asshelp.c @@ -49,7 +49,7 @@ send_one_option (assuan_context_t ctx, gpg_err_source_t errsource, else { err = assuan_transact (ctx, optstr, NULL, NULL, NULL, NULL, NULL, NULL); - free (optstr); + xfree (optstr); } return err; @@ -119,7 +119,7 @@ send_pinentry_environment (assuan_context_t ctx, old_lc = setlocale (LC_CTYPE, NULL); if (old_lc) { - old_lc = strdup (old_lc); + old_lc = xtrystrdup (old_lc); if (!old_lc) return gpg_error_from_syserror (); } @@ -134,7 +134,7 @@ send_pinentry_environment (assuan_context_t ctx, if (old_lc) { setlocale (LC_CTYPE, old_lc); - free (old_lc); + xfree (old_lc); } #endif if (err) @@ -145,7 +145,7 @@ send_pinentry_environment (assuan_context_t ctx, old_lc = setlocale (LC_MESSAGES, NULL); if (old_lc) { - old_lc = strdup (old_lc); + old_lc = xtrystrdup (old_lc); if (!old_lc) return gpg_error_from_syserror (); } @@ -160,7 +160,7 @@ send_pinentry_environment (assuan_context_t ctx, if (old_lc) { setlocale (LC_MESSAGES, old_lc); - free (old_lc); + xfree (old_lc); } #endif if (err) diff --git a/common/homedir.c b/common/homedir.c index 6f1b49c21..eb1e5025a 100644 --- a/common/homedir.c +++ b/common/homedir.c @@ -383,6 +383,12 @@ gnupg_module_name (int which) case GNUPG_MODULE_NAME_GPG: X(bindir, "gpg2"); + case GNUPG_MODULE_NAME_CONNECT_AGENT: + X(bindir, "gpg-connect-agent"); + + case GNUPG_MODULE_NAME_GPGCONF: + X(bindir, "gpgconf"); + default: BUG (); } diff --git a/common/i18n.c b/common/i18n.c index 7db8e20c5..daa147faa 100644 --- a/common/i18n.c +++ b/common/i18n.c @@ -52,6 +52,7 @@ i18n_switchto_utf8 (void) { #ifdef USE_SIMPLE_GETTEXT gettext_select_utf8 (1); + return NULL; #elif defined(ENABLE_NLS) char *orig_codeset = bind_textdomain_codeset (PACKAGE_GT, NULL); # ifdef HAVE_LANGINFO_CODESET @@ -81,6 +82,7 @@ void i18n_switchback (char *saved_codeset) { #ifdef USE_SIMPLE_GETTEXT + (void)saved_codeset; gettext_select_utf8 (0); #elif defined(ENABLE_NLS) if (saved_codeset) diff --git a/common/util.h b/common/util.h index e479cfc4c..269aed193 100644 --- a/common/util.h +++ b/common/util.h @@ -194,6 +194,8 @@ const char *dirmngr_socket_name (void); #define GNUPG_MODULE_NAME_CHECK_PATTERN 6 #define GNUPG_MODULE_NAME_GPGSM 7 #define GNUPG_MODULE_NAME_GPG 8 +#define GNUPG_MODULE_NAME_CONNECT_AGENT 9 +#define GNUPG_MODULE_NAME_GPGCONF 10 const char *gnupg_module_name (int which); |