diff --git a/Makefile b/Makefile index a087eed..bf1a0f9 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,4 @@ -.PHONY: examples -examples: +default: # HelloWorld (non-SSL, non-Zlib compile) $(CC) -DLIBUS_NO_SSL -flto -O3 -c -IuSockets/src uSockets/src/*.c uSockets/src/eventing/*.c $(CXX) -DLIBUS_NO_SSL -DUWS_NO_ZLIB -flto -O3 -c -std=c++17 -Isrc -IuSockets/src examples/HelloWorld.cpp diff --git a/fuzzing/Handshake.cpp b/fuzzing/Handshake.cpp index 39f5ba8..16719f5 100644 --- a/fuzzing/Handshake.cpp +++ b/fuzzing/Handshake.cpp @@ -6,13 +6,13 @@ #include /* We test the websocket handshake generator */ -#include "../src/libwshandshake.hpp" +#include "../src/WebSocketHandshake.h" extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { char output[28]; if (size >= 24) { - WebSocketHandshake::generate((char *) data, output); + uWS::WebSocketHandshake::generate((char *) data, output); } return 0; diff --git a/fuzzing/Makefile b/fuzzing/Makefile index f6fd107..21b0b79 100644 --- a/fuzzing/Makefile +++ b/fuzzing/Makefile @@ -1,5 +1,6 @@ default: +# Fuzzing is only available with clang++ clang++ -std=c++17 -fsanitize=address,fuzzer -O3 WebSocket.cpp -o WebSocket clang++ -std=c++17 -fsanitize=address,fuzzer -O3 Http.cpp -o Http clang++ -std=c++17 -fsanitize=address,fuzzer -O3 Extensions.cpp -o Extensions - clang++ -std=c++17 -fsanitize=address,fuzzer -O3 Handshake.cpp -o Handshake + clang++ -std=c++17 -fsanitize=address,fuzzer -O3 Handshake.cpp -o Handshake \ No newline at end of file