1
0
mirror of git://git.gnupg.org/gnupg.git synced 2025-03-28 22:49:59 +01:00

agent: Fix auth key comment handling.

* agent/command-ssh.c (ssh_send_key_public): Handle the case with no
comment.
This commit is contained in:
NIIBE Yutaka 2014-05-08 11:46:38 +09:00
parent 57011da53e
commit fb24808db9

View File

@ -2331,7 +2331,9 @@ ssh_send_key_public (estream_t stream, gcry_sexp_t key,
else else
{ {
err = ssh_key_extract_comment (key, &comment); err = ssh_key_extract_comment (key, &comment);
if (!err) if (err)
err = stream_write_cstring (stream, "(none)");
else
err = stream_write_cstring (stream, comment); err = stream_write_cstring (stream, comment);
} }
if (err) if (err)