Skip to content

Commit

Permalink
Update cpp-httplib
Browse files Browse the repository at this point in the history
  • Loading branch information
wichtounet committed Nov 22, 2024
1 parent 55980cd commit d9a3460
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cpp-httplib
Submodule cpp-httplib updated 90 files
+5 −0 .clang-format
+2 −0 .gitattributes
+26 −0 .github/workflows/cifuzz.yaml
+65 −0 .github/workflows/test.yaml
+16 −0 .gitignore
+0 −13 .travis.yml
+299 −19 CMakeLists.txt
+11 −0 Dockerfile
+725 −115 README.md
+0 −9 appveyor.yml
+62 −0 benchmark/Makefile
+10,154 −0 benchmark/cpp-httplib-base/httplib.h
+12 −0 benchmark/cpp-httplib-base/main.cpp
+12 −0 benchmark/cpp-httplib/main.cpp
+14,316 −0 benchmark/crow/crow_all.h
+17 −0 benchmark/crow/main.cpp
+2 −0 benchmark/download.sh
+168 −0 cmake/FindBrotli.cmake
+84 −0 cmake/httplibConfig.cmake.in
+7 −0 docker-compose.yml
+21 −0 docker/html/index.html
+81 −0 docker/main.cc
+12 −0 example/Dockerfile.hello
+43 −11 example/Makefile
+1 −1 example/benchmark.cc
+2 −2 example/client.cc
+5 −5 example/client.vcxproj
+1 −1 example/hello.cc
+56 −0 example/one_time_request.cc
+2 −6 example/redirect.cc
+8 −8 example/server.vcxproj
+90 −0 example/server_and_client.cc
+29 −0 example/simplecli.cc
+7 −7 example/simplesvr.cc
+21 −0 example/ssecli.cc
+102 −0 example/ssesvr.cc
+61 −0 example/upload.cc
+6 −0 example/uploader.sh
+9,129 −2,231 httplib.h
+116 −0 meson.build
+10 −0 meson_options.txt
+67 −0 split.py
+121 −0 test/CMakeLists.txt
+61 −14 test/Makefile
+10 −0 test/fuzzing/CMakeLists.txt
+27 −0 test/fuzzing/Makefile
+1 −0 test/fuzzing/corpus/1
+5 −0 test/fuzzing/corpus/2
+ test/fuzzing/corpus/3
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5042094968537088
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5372331946541056
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5386708825800704
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5667822731132928
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5886572146327552
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-5942767436562432
+ test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-6007379124158464
+7 −0 test/fuzzing/corpus/clusterfuzz-testcase-minimized-server_fuzzer-6508706672541696
+19 −0 test/fuzzing/corpus/issue1264
+96 −0 test/fuzzing/server_fuzzer.cc
+224 −0 test/fuzzing/server_fuzzer.dict
+35 −0 test/fuzzing/standalone_fuzz_target_runner.cpp
+18 −0 test/gen-certs.sh
+5,816 −2,433 test/gtest/gtest-all.cc
+9,354 −16,524 test/gtest/gtest.h
+19 −4 test/gtest/gtest_main.cc
+5 −0 test/include_httplib.cc
+144 −0 test/meson.build
+13 −0 test/proxy/Dockerfile
+1 −0 test/proxy/basic_passwd
+81 −0 test/proxy/basic_squid.conf
+1 −0 test/proxy/digest_passwd
+81 −0 test/proxy/digest_squid.conf
+22 −0 test/proxy/docker-compose.yml
+7,451 −1,152 test/test.cc
+3 −0 test/test.conf
+31 −9 test/test.vcxproj
+288 −0 test/test_proxy.cc
+8,192 −0 test/www/dir/1MB.txt
+8 −0 test/www/dir/meson.build
+1 −0 test/www/dir/test.abcde
+0 −0 test/www/empty_file
+1 −0 test/www/file
+7 −0 test/www/meson.build
+1 −0 test/www/日本語Dir/日本語File.txt
+8 −0 test/www2/dir/index.html
+6 −0 test/www2/dir/meson.build
+1 −0 test/www2/dir/test.html
+8 −0 test/www3/dir/index.html
+6 −0 test/www3/dir/meson.build
+1 −0 test/www3/dir/test.html
6 changes: 4 additions & 2 deletions src/api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ budget::api_response base_api_get(Cli& cli, const std::string& api) {
auto base_res = std::make_shared<httplib::Response>();

std::shared_ptr<httplib::Response> res;
if (cli.send(req, *base_res)) {
auto error = httplib::Error::Success;
if (cli.send(req, *base_res, error)) {
res = base_res;
} else {
res = nullptr;
Expand Down Expand Up @@ -110,7 +111,8 @@ budget::api_response base_api_post(Cli& cli, const std::string& api, const std::
auto base_res = std::make_shared<httplib::Response>();

std::shared_ptr<httplib::Response> res;
if (cli.send(req, *base_res)) {
auto error = httplib::Error::Success;
if (cli.send(req, *base_res, error)) {
res = base_res;
} else {
res = nullptr;
Expand Down

0 comments on commit d9a3460

Please sign in to comment.