mirror of
git://git.gnupg.org/gnupg.git
synced 2024-11-10 21:38:50 +01:00
* passphrase.c (agent_get_passphrase): Make sure to release the
saved codeset. (agent_open): Add arg ORIG_CODESET and switch back to it in case of error. Changed all callers. * zh_TW.po, fr.po, cs.po: Updated.
This commit is contained in:
parent
862652ebe1
commit
a7ea40e4f8
@ -48,7 +48,7 @@ named "gnupg" below the application data directory of the user. This
|
|||||||
directory will be created if it does not exist. Being only a default,
|
directory will be created if it does not exist. Being only a default,
|
||||||
it may be changed by setting the name of the home directory into the
|
it may be changed by setting the name of the home directory into the
|
||||||
Registry under the key HKEY_CURRENT_USER\Software\GNU\GnuPG using the
|
Registry under the key HKEY_CURRENT_USER\Software\GNU\GnuPG using the
|
||||||
name "HomeDir". If an environment varaibale "GNUPGHOME" exists, this
|
name "HomeDir". If an environment variable "GNUPGHOME" exists, this
|
||||||
even overrides the registry setting. The command line option
|
even overrides the registry setting. The command line option
|
||||||
"--homedir" may be used to override all other settings of the home
|
"--homedir" may be used to override all other settings of the home
|
||||||
directory.
|
directory.
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
2005-07-26 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
|
* passphrase.c (agent_get_passphrase): Make sure to release the
|
||||||
|
saved codeset.
|
||||||
|
(agent_open): Add arg ORIG_CODESET and switch back to it in case
|
||||||
|
of error. Changed all callers.
|
||||||
|
|
||||||
2005-07-22 David Shaw <dshaw@jabberwocky.com>
|
2005-07-22 David Shaw <dshaw@jabberwocky.com>
|
||||||
|
|
||||||
* keyedit.c (sign_uids): Don't prompt for setting signature expiry
|
* keyedit.c (sign_uids): Don't prompt for setting signature expiry
|
||||||
|
@ -83,7 +83,7 @@ static assuan_error_t learn_status_cb (void *opaque, const char *line);
|
|||||||
#define ASSUAN_LINELENGTH 100
|
#define ASSUAN_LINELENGTH 100
|
||||||
|
|
||||||
static assuan_context_t
|
static assuan_context_t
|
||||||
agent_open (int try)
|
agent_open (int try, const char *orig_codeset)
|
||||||
{
|
{
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
@ -338,7 +338,7 @@ open_card_via_agent (int *scd_available)
|
|||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
*scd_available = 0;
|
*scd_available = 0;
|
||||||
ctx = agent_open (1);
|
ctx = agent_open (1, NULL);
|
||||||
if (!ctx)
|
if (!ctx)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
@ -189,7 +189,7 @@ int build_sk_list( STRLIST locusr, SK_LIST *ret_sk_list,
|
|||||||
|
|
||||||
/*-- passphrase.h --*/
|
/*-- passphrase.h --*/
|
||||||
#ifdef ENABLE_AGENT_SUPPORT
|
#ifdef ENABLE_AGENT_SUPPORT
|
||||||
assuan_context_t agent_open (int try);
|
assuan_context_t agent_open (int try, const char *orig_codeset);
|
||||||
void agent_close (assuan_context_t ctx);
|
void agent_close (assuan_context_t ctx);
|
||||||
#else
|
#else
|
||||||
/* If we build w/o agent support, assuan.h won't get included and thus
|
/* If we build w/o agent support, assuan.h won't get included and thus
|
||||||
|
@ -275,10 +275,12 @@ agent_send_all_options (assuan_context_t ctx)
|
|||||||
* Returns: -1 on error; on success an Assuan context for that
|
* Returns: -1 on error; on success an Assuan context for that
|
||||||
* connection is returned. With TRY set to true, no error messages
|
* connection is returned. With TRY set to true, no error messages
|
||||||
* are printed and the use of the agent won't get disabled on failure.
|
* are printed and the use of the agent won't get disabled on failure.
|
||||||
|
* If ORIG_CODESET is not NULL, the function will swithc the codeset
|
||||||
|
* back to that one before printing error messages.
|
||||||
*/
|
*/
|
||||||
#ifdef ENABLE_AGENT_SUPPORT
|
#ifdef ENABLE_AGENT_SUPPORT
|
||||||
assuan_context_t
|
assuan_context_t
|
||||||
agent_open (int try)
|
agent_open (int try, const char *orig_codeset)
|
||||||
{
|
{
|
||||||
int rc;
|
int rc;
|
||||||
assuan_context_t ctx;
|
assuan_context_t ctx;
|
||||||
@ -295,6 +297,10 @@ agent_open (int try)
|
|||||||
{
|
{
|
||||||
if (!try)
|
if (!try)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
if (orig_codeset)
|
||||||
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
#endif /*ENABLE_NLS*/
|
||||||
log_error (_("gpg-agent is not available in this session\n"));
|
log_error (_("gpg-agent is not available in this session\n"));
|
||||||
opt.use_agent = 0;
|
opt.use_agent = 0;
|
||||||
}
|
}
|
||||||
@ -307,6 +313,10 @@ agent_open (int try)
|
|||||||
{
|
{
|
||||||
if (!try)
|
if (!try)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
if (orig_codeset)
|
||||||
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
#endif /*ENABLE_NLS*/
|
||||||
log_error ( _("malformed GPG_AGENT_INFO environment variable\n"));
|
log_error ( _("malformed GPG_AGENT_INFO environment variable\n"));
|
||||||
opt.use_agent = 0;
|
opt.use_agent = 0;
|
||||||
}
|
}
|
||||||
@ -322,6 +332,10 @@ agent_open (int try)
|
|||||||
{
|
{
|
||||||
if (!try)
|
if (!try)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
if (orig_codeset)
|
||||||
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
#endif /*ENABLE_NLS*/
|
||||||
log_error (_("gpg-agent protocol version %d is not supported\n"),
|
log_error (_("gpg-agent protocol version %d is not supported\n"),
|
||||||
prot);
|
prot);
|
||||||
opt.use_agent = 0;
|
opt.use_agent = 0;
|
||||||
@ -335,6 +349,10 @@ agent_open (int try)
|
|||||||
{
|
{
|
||||||
if (!try)
|
if (!try)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
if (orig_codeset)
|
||||||
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
#endif /*ENABLE_NLS*/
|
||||||
log_error ( _("can't connect to `%s': %s\n"),
|
log_error ( _("can't connect to `%s': %s\n"),
|
||||||
infostr, assuan_strerror (rc));
|
infostr, assuan_strerror (rc));
|
||||||
opt.use_agent = 0;
|
opt.use_agent = 0;
|
||||||
@ -348,6 +366,10 @@ agent_open (int try)
|
|||||||
{
|
{
|
||||||
if (!try)
|
if (!try)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
if (orig_codeset)
|
||||||
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
#endif /*ENABLE_NLS*/
|
||||||
log_error (_("problem with the agent - disabling agent use\n"));
|
log_error (_("problem with the agent - disabling agent use\n"));
|
||||||
opt.use_agent = 0;
|
opt.use_agent = 0;
|
||||||
}
|
}
|
||||||
@ -485,7 +507,7 @@ agent_get_passphrase ( u32 *keyid, int mode, const char *cacheid,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if ( !(ctx = agent_open (0)) )
|
if ( !(ctx = agent_open (0, orig_codeset)) )
|
||||||
goto failure;
|
goto failure;
|
||||||
|
|
||||||
if (custom_description)
|
if (custom_description)
|
||||||
@ -633,7 +655,10 @@ agent_get_passphrase ( u32 *keyid, int mode, const char *cacheid,
|
|||||||
failure:
|
failure:
|
||||||
#ifdef ENABLE_NLS
|
#ifdef ENABLE_NLS
|
||||||
if (orig_codeset)
|
if (orig_codeset)
|
||||||
|
{
|
||||||
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
bind_textdomain_codeset (PACKAGE, orig_codeset);
|
||||||
|
xfree (orig_codeset);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
xfree (atext);
|
xfree (atext);
|
||||||
agent_close (ctx);
|
agent_close (ctx);
|
||||||
@ -683,7 +708,7 @@ passphrase_clear_cache ( u32 *keyid, const char *cacheid, int algo )
|
|||||||
else
|
else
|
||||||
pk = NULL;
|
pk = NULL;
|
||||||
|
|
||||||
if ( !(ctx = agent_open (0)) )
|
if ( !(ctx = agent_open (0, NULL)) )
|
||||||
goto failure;
|
goto failure;
|
||||||
|
|
||||||
{
|
{
|
||||||
|
@ -1,3 +1,11 @@
|
|||||||
|
2005-07-26 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
|
* zh_TW.po, fr.po, cs.po: Updated.
|
||||||
|
|
||||||
|
2005-07-19 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
|
* ru.po: Updated.
|
||||||
|
|
||||||
2005-06-21 Werner Koch <wk@g10code.com>
|
2005-06-21 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
* zh_TW.po: Updated.
|
* zh_TW.po: Updated.
|
||||||
|
992
po/pt_BR.po
992
po/pt_BR.po
File diff suppressed because it is too large
Load Diff
985
po/zh_CN.po
985
po/zh_CN.po
File diff suppressed because it is too large
Load Diff
1017
po/zh_TW.po
1017
po/zh_TW.po
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user