27 Jul
2011
27 Jul
'11
9:25 a.m.
I would like to get something like this:
async_accept(socket, [=] (const boost::system::error_code &error) { // });
if (!error) { //here there are a valid connection }
"error" is just an argument of the anonymous function (lambda), and it's accessible only inside that function (like any other function argument). What do you try to achieve?