[client] fix return value in spice_read_nl error path

Returning -1 from a function with bool as return argument is the same as
returning true. If the channel is not connected, return false instead to
indicate the error.
This commit is contained in:
Rikard Falkeborn 2019-12-17 22:08:27 +01:00 committed by Geoffrey McRae
parent 0bd19cfd38
commit 6530ca62da

View File

@ -1286,7 +1286,7 @@ bool spice_read_nl(const struct SpiceChannel * channel, void * buffer, const ssi
if (!channel->connected)
{
DEBUG_ERROR("not connected");
return -1;
return false;
}
if (!buffer)