mirror of
git://git.gnupg.org/gnupg.git
synced 2025-05-24 16:43:28 +02:00
agent: Avoid double error message.
* agent/gpg-agent.c (map_supervised_sockets): Shorten error message. Remove unneeded diagnostic. -- get_socket_name already prints error messages and thus there is not need to print another one. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
ece13f177d
commit
b77f95a4a6
@ -717,18 +717,17 @@ map_supervised_sockets (gnupg_fd_t *r_fd,
|
|||||||
if (!fdnames)
|
if (!fdnames)
|
||||||
{
|
{
|
||||||
struct stat statbuf;
|
struct stat statbuf;
|
||||||
|
|
||||||
if (fd_count != 1)
|
if (fd_count != 1)
|
||||||
log_error ("no LISTEN_FDNAMES and LISTEN_FDS (%d) != 1"
|
log_error ("no LISTEN_FDNAMES and LISTEN_FDS (%d) != 1"
|
||||||
" in --supervised mode."
|
" in --supervised mode."
|
||||||
" (ignoring all sockets but the first one)\n",
|
" (ignoring all sockets but the first one)\n",
|
||||||
fd_count);
|
fd_count);
|
||||||
if (fstat (3, &statbuf) == -1 && errno ==EBADF)
|
if (fstat (3, &statbuf) == -1 && errno ==EBADF)
|
||||||
log_fatal ("file descriptor 3 must be valid in --supervised mode (as the "
|
log_fatal ("file descriptor 3 must be valid in --supervised mode"
|
||||||
"agent's standard socket) if LISTEN_FDNAMES is not set\n");
|
" if LISTEN_FDNAMES is not set\n");
|
||||||
*r_fd = 3;
|
*r_fd = 3;
|
||||||
socket_name = get_socket_name (3);
|
socket_name = get_socket_name (3);
|
||||||
if (!socket_name)
|
|
||||||
log_error ("cannot learn socket name for fd 3\n");
|
|
||||||
}
|
}
|
||||||
else if (fd_count != nfdnames)
|
else if (fd_count != nfdnames)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user