]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
Don't assert if daemon returns empty string answer to client
authorRay Strode <rstrode@redhat.com>
Tue, 3 Jun 2008 15:07:39 +0000 (11:07 -0400)
committerRay Strode <rstrode@redhat.com>
Tue, 3 Jun 2008 15:10:39 +0000 (11:10 -0400)
src/client/ply-boot-client.c

index c3498376f929e90c0ec236ff8e6e7e5802a5b2a2..6edc3e6da656b62dd92a95da6ebe1174af91a3a8 100644 (file)
@@ -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);
     }