tools: Fix condition for gpg-connect-agent.
authorNIIBE Yutaka <gniibe@fsij.org>
Wed, 12 Apr 2017 07:01:16 +0000 (16:01 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Wed, 12 Apr 2017 07:01:16 +0000 (16:01 +0900)
* tools/gpg-connect-agent.c (start_agent): Add paren.

--

The intention is comparing the error code depending opt.use_dirmngr.
Considering C Operator Precedence, we should have paren here.

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
tools/gpg-connect-agent.c

index ef71d27..f20d331 100644 (file)
@@ -2237,7 +2237,7 @@ start_agent (void)
     {
       if (!opt.autostart
           && (gpg_err_code (err)
-              == opt.use_dirmngr? GPG_ERR_NO_DIRMNGR : GPG_ERR_NO_AGENT))
+              == (opt.use_dirmngr? GPG_ERR_NO_DIRMNGR : GPG_ERR_NO_AGENT)))
         {
           /* In the no-autostart case we don't make gpg-connect-agent
              fail on a missing server.  */