1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00

tools: Add TPM2DAEMON_SOCK_NAME for --remove-socketdir.

* tools/gpgconf.c (main): Care about tpm2d.  Emit correct ERR.

--

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2023-10-03 16:51:46 +09:00
parent 321f9c0a3f
commit 25c84ffd10
No known key found for this signature in database
GPG Key ID: 640114AF89DE6054

View File

@ -963,7 +963,8 @@ main (int argc, char **argv)
GPG_AGENT_SSH_SOCK_NAME,
SCDAEMON_SOCK_NAME,
KEYBOXD_SOCK_NAME,
DIRMNGR_SOCK_NAME
DIRMNGR_SOCK_NAME,
TPM2DAEMON_SOCK_NAME
};
int i;
char *p;
@ -976,9 +977,12 @@ main (int argc, char **argv)
xfree (p);
}
if (gnupg_rmdir (socketdir))
{
err = gpg_error_from_syserror ();
gc_error (1, 0, "error removing '%s': %s",
socketdir, gpg_strerror (err));
}
}
else if (gpg_err_code (err) == GPG_ERR_ENOENT)
gc_error (0, 0, "warning: removing '%s' failed: %s",
socketdir, gpg_strerror (err));