24 Jan
2009
24 Jan
'09
7:19 p.m.
2009/1/23 Johan Mazel
Thanks a lot for the fast answer.
I have another question about the boost::mutable_buffer since they are used to send and receive payload through the upd socket with the methods send_to and receive_from. I'd like to know how can I assign the content of a mutable_buffer to a char * ? I found the method buffer_cast ( http://www.boost.org/doc/libs/1_37_0/doc/html/boost_asio/reference/mutable_b...) but I don't really understand how to use it.
You can use it just as described here: http://www.boost.org/doc/libs/1_37_0/doc/html/boost_asio/reference/buffer.ht... But in most cases you don't need this function, as you've got more safe ways to get the data (please refer to the asio tutorial and examples).