[git] GnuPG - branch, master, updated. gnupg-2.1.13-137-g7be2181
by NIIBE Yutaka
cvs at cvs.gnupg.org
Wed Jul 13 02:27:51 CEST 2016
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".
The branch, master has been updated
via 7be218177701af316db75057c99ca674d53cf585 (commit)
from acb27915f8646a875b6bb507ff46cd1bc330c02b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 7be218177701af316db75057c99ca674d53cf585
Author: NIIBE Yutaka <gniibe at fsij.org>
Date: Wed Jul 13 09:24:26 2016 +0900
agent: Fix envvars for UPDATESTARTUPTTY.
agent/command.c (cmd_updatestartuptty): Use session_env_list_stdenvnames
to get the list.
--
Debian-bug-id: 801247
Signed-off-by: NIIBE Yutaka <gniibe at fsij.org>
diff --git a/agent/command.c b/agent/command.c
index de5b184..e5d2268 100644
--- a/agent/command.c
+++ b/agent/command.c
@@ -2663,14 +2663,13 @@ static const char hlp_updatestartuptty[] =
static gpg_error_t
cmd_updatestartuptty (assuan_context_t ctx, char *line)
{
- static const char *names[] =
- { "GPG_TTY", "DISPLAY", "TERM", "XAUTHORITY", "PINENTRY_USER_DATA", NULL };
ctrl_t ctrl = assuan_get_pointer (ctx);
gpg_error_t err = 0;
session_env_t se;
- int idx;
char *lc_ctype = NULL;
char *lc_messages = NULL;
+ int iterator;
+ const char *name;
(void)line;
@@ -2681,11 +2680,12 @@ cmd_updatestartuptty (assuan_context_t ctx, char *line)
if (!se)
err = gpg_error_from_syserror ();
- for (idx=0; !err && names[idx]; idx++)
+ iterator = 0;
+ while (!err && (name = session_env_list_stdenvnames (&iterator, NULL)))
{
- const char *value = session_env_getenv (ctrl->session_env, names[idx]);
+ const char *value = session_env_getenv (ctrl->session_env, name);
if (value)
- err = session_env_setenv (se, names[idx], value);
+ err = session_env_setenv (se, name, value);
}
if (!err && ctrl->lc_ctype)
-----------------------------------------------------------------------
Summary of changes:
agent/command.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
hooks/post-receive
--
The GNU Privacy Guard
http://git.gnupg.org
More information about the Gnupg-commits
mailing list