Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ test_install
builds
build-linux
vcpkg_installed
.DS_Store
9 changes: 8 additions & 1 deletion libraries/http_server/http_server/http_ctx.hh
Original file line number Diff line number Diff line change
Expand Up @@ -816,7 +816,14 @@ template <typename F> auto make_http_processor(F handler) {
ctx.flush_responses();
}
}
catch (const std::runtime_error& e) {
catch (fiber_exception&) {
// Used internally (e.g. idle timeout, EPOLLRDHUP) to unwind the fiber via
// boost::context's exception-forwarding protocol. Must propagate to the
// callcc entry point in tcp_server.hh, which returns the continuation
// carried by the exception. Swallowing it here leaves boost::context's
// bookkeeping inconsistent and later crashes with a forced_unwind.
throw;
} catch (const std::runtime_error& e) {
std::cerr << "Error: " << e.what() << std::endl;
return;
} catch (...) {
Expand Down
9 changes: 8 additions & 1 deletion single_headers/lithium.hh
Original file line number Diff line number Diff line change
Expand Up @@ -10415,7 +10415,14 @@ template <typename F> auto make_http_processor(F handler) {
ctx.flush_responses();
}
}
catch (const std::runtime_error& e) {
catch (fiber_exception&) {
// Used internally (e.g. idle timeout, EPOLLRDHUP) to unwind the fiber via
// boost::context's exception-forwarding protocol. Must propagate to the
// callcc entry point in tcp_server.hh, which returns the continuation
// carried by the exception. Swallowing it here leaves boost::context's
// bookkeeping inconsistent and later crashes with a forced_unwind.
throw;
} catch (const std::runtime_error& e) {
std::cerr << "Error: " << e.what() << std::endl;
return;
} catch (...) {
Expand Down
9 changes: 8 additions & 1 deletion single_headers/lithium_http_server.hh
Original file line number Diff line number Diff line change
Expand Up @@ -7206,7 +7206,14 @@ template <typename F> auto make_http_processor(F handler) {
ctx.flush_responses();
}
}
catch (const std::runtime_error& e) {
catch (fiber_exception&) {
// Used internally (e.g. idle timeout, EPOLLRDHUP) to unwind the fiber via
// boost::context's exception-forwarding protocol. Must propagate to the
// callcc entry point in tcp_server.hh, which returns the continuation
// carried by the exception. Swallowing it here leaves boost::context's
// bookkeeping inconsistent and later crashes with a forced_unwind.
throw;
} catch (const std::runtime_error& e) {
std::cerr << "Error: " << e.what() << std::endl;
return;
} catch (...) {
Expand Down
2 changes: 1 addition & 1 deletion vcpkg
Submodule vcpkg updated 3361 files
Loading