Skip to content
This repository was archived by the owner on Jun 12, 2018. It is now read-only.

Commit 6381ee1

Browse files
committed
Fixes #146: added comment to server.on_error examples regarding connection timeouts
1 parent fb4a17d commit 6381ee1

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

http_examples.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,7 @@ int main() {
202202

203203
server.on_error = [](shared_ptr<HttpServer::Request> /*request*/, const SimpleWeb::error_code & /*ec*/) {
204204
// Handle errors here
205+
// Note that connection timeouts will also call this handle with ec set to SimpleWeb::errc::operation_canceled
205206
};
206207

207208
thread server_thread([&server]() {

https_examples.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@ int main() {
200200

201201
server.on_error = [](shared_ptr<HttpsServer::Request> /*request*/, const SimpleWeb::error_code & /*ec*/) {
202202
// Handle errors here
203+
// Note that connection timeouts will also call this handle with ec set to SimpleWeb::errc::operation_canceled
203204
};
204205

205206
thread server_thread([&server]() {

0 commit comments

Comments
 (0)