From e1c8a6c2e26283cd57588fb18125c7bcdefdb8c9 Mon Sep 17 00:00:00 2001 From: Richard Russon Date: Mon, 10 Apr 2017 22:18:59 +0100 Subject: [PATCH] pgp_use_gpg_agent --- pgp.c | 6 +++--- pgp.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pgp.c b/pgp.c index 8a91b6480..eb723e6a4 100644 --- a/pgp.c +++ b/pgp.c @@ -95,18 +95,18 @@ int pgp_valid_passphrase (void) return 0; } -int pgp_use_gpg_agent (void) +bool pgp_use_gpg_agent (void) { char *tty = NULL; /* GnuPG 2.1 no longer exports GPG_AGENT_INFO */ if (!option (OPTUSEGPGAGENT)) - return 0; + return false; if ((tty = ttyname(0))) setenv("GPG_TTY", tty, 0); - return 1; + return true; } static pgp_key_t _pgp_parent(pgp_key_t k) diff --git a/pgp.h b/pgp.h index 5236bf692..e3942fbc1 100644 --- a/pgp.h +++ b/pgp.h @@ -28,7 +28,7 @@ /* prototypes */ -int pgp_use_gpg_agent(void); +bool pgp_use_gpg_agent(void); int pgp_check_traditional(FILE *fp, BODY *b, int tagged_only); BODY *pgp_make_key_attachment(char *tempf); -- 2.40.0