From: Ray Strode Date: Tue, 3 Jun 2008 15:07:39 +0000 (-0400) Subject: Don't assert if daemon returns empty string answer to client X-Git-Tag: 0.2.0~47^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4f003fd471789aec345f482b134272dc084b9e30;p=thirdparty%2Fplymouth.git Don't assert if daemon returns empty string answer to client --- diff --git a/src/client/ply-boot-client.c b/src/client/ply-boot-client.c index c3498376..6edc3e6d 100644 --- a/src/client/ply-boot-client.c +++ b/src/client/ply-boot-client.c @@ -264,8 +264,11 @@ ply_boot_client_process_incoming_replies (ply_boot_client_t *client) if (!ply_read (client->socket_fd, &size, sizeof (uint8_t))) goto out; - if (!ply_read (client->socket_fd, answer, size)) - goto out; + if (size > 0) + { + if (!ply_read (client->socket_fd, answer, size)) + goto out; + } ((ply_boot_client_answer_handler_t) request->handler) (request->user_data, answer, client); }