aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Janouch <p@janouch.name>2018-10-16 04:05:42 +0200
committerPřemysl Janouch <p@janouch.name>2018-10-16 04:05:42 +0200
commit7cefdd496f8e45a5d4ee54b7c6cfc5283ae32d51 (patch)
treec86331b53c49c55a56b99d116f91d13314bc75d1
parente9530f450e64947850da0ed7596c8611cf445efe (diff)
downloadjson-rpc-shell-7cefdd496f8e45a5d4ee54b7c6cfc5283ae32d51.tar.gz
json-rpc-shell-7cefdd496f8e45a5d4ee54b7c6cfc5283ae32d51.tar.xz
json-rpc-shell-7cefdd496f8e45a5d4ee54b7c6cfc5283ae32d51.zip
Cleanup
-rw-r--r--demo-json-rpc-server.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/demo-json-rpc-server.c b/demo-json-rpc-server.c
index 2c487f5..4ec7e4c 100644
--- a/demo-json-rpc-server.c
+++ b/demo-json-rpc-server.c
@@ -2218,21 +2218,21 @@ client_ws_close_cb (struct ws_handler *handler)
static void
client_ws_shutdown (struct client *client)
{
- struct client_ws *self = (struct client_ws *) client;
+ FIND_CONTAINER (self, client, struct client_ws, client);
ws_handler_close (&self->handler, WS_STATUS_GOING_AWAY, NULL, 0);
}
static void
client_ws_destroy (struct client *client)
{
- struct client_ws *self = (struct client_ws *) client;
+ FIND_CONTAINER (self, client, struct client_ws, client);
ws_handler_free (&self->handler);
}
static bool
client_ws_push (struct client *client, const void *data, size_t len)
{
- struct client_ws *self = (struct client_ws *) client;
+ FIND_CONTAINER (self, client, struct client_ws, client);
return ws_handler_push (&self->handler, data, len);
}