Boost logo

Boost Users :

Subject: Re: [Boost-users] async accept asio thread error
From: Igor R (boost.lists_at_[hidden])
Date: 2011-04-06 04:03:57

> No, I'm sorry I forgot one line at the end:
> thread = boost::thread(boost::bind(&boost::asio::io_service::run,
> &io_service));

Ok, but this line just creates a thread and passes to it
io_service::run() -- it doesn't block your current thread, where you
issued async_accept.
Ensure that the thread where you *call* async_accept() doesn't ends
before the operation is complete.

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at