agent: Simplify stream_read_cstring.

* agent/command-ssh.c (stream_read_cstring): Just call
stream_read_string.

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2017-04-12 09:24:48 +09:00
parent 64904ce627
commit c64763c3a7
1 changed files with 1 additions and 7 deletions

View File

@ -674,13 +674,7 @@ stream_read_blob (estream_t stream, unsigned int secure, gcry_mpi_t *r_mpi)
static gpg_error_t
stream_read_cstring (estream_t stream, char **string)
{
gpg_error_t err;
unsigned char *buffer;
err = stream_read_string (stream, 0, &buffer, NULL);
if (!err)
*string = (char *)buffer;
return err;
return stream_read_string (stream, 0, (unsigned char **)string, NULL);
}