@@ -242,7 +242,7 @@ namespace SimpleWeb {
242
242
}
243
243
244
244
// Set timeout on the following boost::asio::async-read or write function
245
- auto timer=get_timeout_timer (socket, timeout_request);
245
+ auto timer=this -> get_timeout_timer (socket, timeout_request);
246
246
247
247
boost::asio::async_read_until (*socket, request->streambuf , " \r\n\r\n " ,
248
248
[this , socket, request, timer](const boost::system ::error_code& ec, size_t bytes_transferred) {
@@ -255,7 +255,7 @@ namespace SimpleWeb {
255
255
// streambuf (maybe some bytes of the content) is appended to in the async_read-function below (for retrieving content).
256
256
size_t num_additional_bytes=request->streambuf .size ()-bytes_transferred;
257
257
258
- if (!parse_request (request))
258
+ if (!this -> parse_request (request))
259
259
return ;
260
260
261
261
// If content, read that as well
@@ -272,22 +272,22 @@ namespace SimpleWeb {
272
272
}
273
273
if (content_length>num_additional_bytes) {
274
274
// Set timeout on the following boost::asio::async-read or write function
275
- auto timer=get_timeout_timer (socket, timeout_content);
275
+ auto timer=this -> get_timeout_timer (socket, timeout_content);
276
276
boost::asio::async_read (*socket, request->streambuf ,
277
277
boost::asio::transfer_exactly (content_length-num_additional_bytes),
278
278
[this , socket, request, timer]
279
279
(const boost::system ::error_code& ec, size_t /* bytes_transferred*/ ) {
280
280
if (timer)
281
281
timer->cancel ();
282
282
if (!ec)
283
- find_resource (socket, request);
283
+ this -> find_resource (socket, request);
284
284
});
285
285
}
286
286
else
287
- find_resource (socket, request);
287
+ this -> find_resource (socket, request);
288
288
}
289
289
else
290
- find_resource (socket, request);
290
+ this -> find_resource (socket, request);
291
291
}
292
292
});
293
293
}
@@ -357,11 +357,11 @@ namespace SimpleWeb {
357
357
std::function<void (std::shared_ptr<typename ServerBase<socket_type>::Response>,
358
358
std::shared_ptr<typename ServerBase<socket_type>::Request>)>& resource_function) {
359
359
// Set timeout on the following boost::asio::async-read or write function
360
- auto timer=get_timeout_timer (socket, timeout_content);
360
+ auto timer=this -> get_timeout_timer (socket, timeout_content);
361
361
362
362
auto response=std::shared_ptr<Response>(new Response (socket), [this , request, timer](Response *response_ptr) {
363
363
auto response=std::shared_ptr<Response>(response_ptr);
364
- send (response, [this , response, request, timer](const boost::system ::error_code& ec) {
364
+ this -> send (response, [this , response, request, timer](const boost::system ::error_code& ec) {
365
365
if (timer)
366
366
timer->cancel ();
367
367
if (!ec) {
@@ -381,7 +381,7 @@ namespace SimpleWeb {
381
381
return ;
382
382
}
383
383
if (http_version>1.05 )
384
- read_request_and_content (response->socket );
384
+ this -> read_request_and_content (response->socket );
385
385
}
386
386
});
387
387
});
@@ -423,7 +423,7 @@ namespace SimpleWeb {
423
423
boost::asio::ip::tcp::no_delay option (true );
424
424
socket->set_option (option);
425
425
426
- read_request_and_content (socket);
426
+ this -> read_request_and_content (socket);
427
427
}
428
428
});
429
429
}
0 commit comments