aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Green <andy.green@linaro.org>2013-01-23 09:09:58 +0800
committerAndy Green <andy.green@linaro.org>2013-01-23 09:09:58 +0800
commit06fc218030ad259cb8076f1e4a2e1eea5f1722f5 (patch)
tree8fb171959a668f19d5f45dc33b5b3dea79a0c2d8
parentb3120f0c6e3d77b1654883c59828b787dd759d28 (diff)
update for libwebsocket api changes
Signed-off-by: Andy Green <andy.green@linaro.org>
-rw-r--r--aepd/main.c3
-rw-r--r--aepd/websocket-protocol.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/aepd/main.c b/aepd/main.c
index 080381d..8b45419 100644
--- a/aepd/main.c
+++ b/aepd/main.c
@@ -214,7 +214,8 @@ int main(int argc, char *argv[])
context = libwebsocket_create_context(port, interface_ptr, protocols,
NULL,
- cert_path, key_path, -1, -1, opts, NULL);
+ cert_path, key_path, NULL,
+ -1, -1, opts, NULL);
if (context == NULL) {
fprintf(stderr, "libwebsocket init failed\n");
return -1;
diff --git a/aepd/websocket-protocol.c b/aepd/websocket-protocol.c
index e3b3e64..1937a94 100644
--- a/aepd/websocket-protocol.c
+++ b/aepd/websocket-protocol.c
@@ -62,7 +62,8 @@ static int callback_http(struct libwebsocket_context *context,
sprintf(buf, LOCAL_RESOURCE_PATH"%s", whitelist[n].urlpath);
- if (libwebsockets_serve_http_file(wsi, buf, whitelist[n].mimetype))
+ if (libwebsockets_serve_http_file(context, wsi, buf,
+ whitelist[n].mimetype))
fprintf(stderr, "Failed to send HTTP file\n");
break;