Fix capi bug, add Makefile
This commit is contained in:
+1
-1
@@ -21,7 +21,7 @@ extern "C" {
|
||||
|
||||
void uws_res_end(uws_res_t *res, const char *data, size_t length) {
|
||||
uWS::HttpResponse<false> *uwsRes = (uWS::HttpResponse<false> *) res;
|
||||
uwsRes->end(data, length);
|
||||
uwsRes->end(std::string_view(data, length));
|
||||
}
|
||||
|
||||
void uws_app_listen(uws_app_t *app, int port, void (*handler)(void *)) {
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
default:
|
||||
make -C ../uSockets
|
||||
g++ -O3 -std=c++17 -flto -DUWS_NO_ZLIB -I ../src -I ../uSockets/src App.cpp -c
|
||||
gcc -O3 -flto example.c *.o -lstdc++ ../uSockets/uSockets.a -o example
|
||||
Reference in New Issue
Block a user