impl_type::
close()
{
- socket.close();
+ {
+ error_code ec;
+ socket.close(ec);
+ }
timer.cancel();
+
// have to let the read/write ops cancel the timer,
// otherwise we will get error::timeout on close when
// we actually want net::error::operation_aborted.