Boost logo

Boost Users :

Subject: [Boost-users] Why can I not put a break in this part of asio sample code?
From: Ozgur Ozturk (ozgur7_at_[hidden])
Date: 2009-07-12 20:06:13


Hi,
    I am using the
async_tcp_echo_server.cpp<http://www.boost.org/doc/libs/1_39_0/doc/html/boost_asio/example/echo/async_tcp_echo_server.cpp>sample
code to understand asio.
when I am tracing code in visual studio, it doeasn't let me put a breakpoint
inside start() function in session class.
Will it be run in another thread? is that the reason for not being able to
put a breakpoint?
Though it seems I can put breakpints for other codes that run in other
threads...
Why can I not put here?

I tried to break at the point calling this function and step into from
there.
it jumps to async_receive(...) function in win_iocp_socket_service.hpp file.

Could someone help me understand what is going on, or give me some pointers
about how to trace such code?
TIA,
Ozgur
PS: here is the related code:

class session
{
//...
//this is the part I can not put breakpoint.
  void start()
  {
    socket_.async_read_some(boost::asio::buffer(data_, max_length),
        boost::bind(&session::handle_read, this,
          boost::asio::placeholders::error,
          boost::asio::placeholders::bytes_transferred));
  }

Best regards,
Ozgur (Oscar) Ozturk
www.DrOzgur.com
+1 (614) 805-4370



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