Boost logo

Boost Users :

Subject: [Boost-users] issues when using boost.bind from boost.thread
From: Sean Farrow (sean.farrow_at_[hidden])
Date: 2011-03-23 02:34:39


Hi:
I'm trying to use boost.bind when starting a thread.
The following code starts a thread and tries to pass in a boost.asio.io_service as well.
boost::thread* t = new boost::thread(boost::bind(&boost::asio::io_service::run, &io));
I'm getting the following exception when running this code.
Unhandled exception at 0x7c812afb in MDRLite.exe: Microsoft C++ exception: boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::system::system_error> >
Removing the previous block of code removes the error.
Having read the boost.bind, The boost.tread/boost.asio documentation I carn't seem to find what is wrong.
This seems to be the final piece of the jigsaw that I carn't seem to crack!
Any help appreciated.
Cheers
Sean.



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net