Correctly pass string data from client to server.

This commit is contained in:
Martin Baulig
2000-01-09 22:12:49 +00:00
parent fa592c3a94
commit c164df664d
2 changed files with 21 additions and 4 deletions

View File

@@ -63,9 +63,16 @@ glibtop_call_i (glibtop *server, glibtop_backend *backend, unsigned command,
} else {
cmnd.send_size = send_size;
}
cmnd.data_size = data_size;
glibtop_write_i (server, backend, sizeof (glibtop_command), &cmnd);
if (data_size) {
fprintf (stderr, "SENDING %d bytes of DATA.\n", data_size);
glibtop_write_i (server, backend, data_size, data_buf);
}
glibtop_read_i (server, backend, sizeof (glibtop_response), &resp);
fprintf (stderr, "RESPONSE: %d - %d - %ld - %ld - %p - %ld\n",