
When I run a second instance of multicast/receiver on FreeBSD 6.2-PRERELEASE I get ENOMEM thrown from socket_.bind. I set a conditional breakpoint on return from error_wrapper and I see that errno is 48 (EADDRINUSE). (gdb) run 0.0.0.0 239.255.0.1 The program being debugged has been started already. Start it from the beginning? (y or n) y Starting program: /home/alnsn/src/boost/branches/HEAD/bin/boost/libs/asio/exampl e/multicast/receiver/gcc/debug/threading-multi/receiver 0.0.0.0 239.255.0.1 warning: Unable to get location for thread creation breakpoint: generic error [New LWP 100051] [New Thread 0x8064000 (LWP 100051)] [Switching to Thread 0x8064000 (LWP 100051)] Breakpoint 5, boost::asio::detail::socket_ops::error_wrapper<int> ( return_value=-1, ec=@0xbfbfe140) at socket_ops.hpp:59 59 return return_value; (gdb) print errno $11 = 48 (gdb) bt #0 boost::asio::detail::socket_ops::error_wrapper<int> (return_value=-1, ec=@0xbfbfe140) at socket_ops.hpp:59 #1 0x0804df84 in boost::asio::detail::socket_ops::bind (s=5, addr=0xbfbfe1a0, addrlen=16, ec=@0xbfbfe140) at socket_ops.hpp:90 #2 0x0804df41 in boost::asio::detail::reactive_socket_service<boost::asio::ip:: udp, boost::asio::detail::select_reactor<false> >::bind (this=0x805b0e0, impl=@0xbfbfe2a4, endpoint=@0xbfbfe1a0, ec=@0xbfbfe140) at reactive_socket_service.hpp:240 #3 0x0804cd7e in boost::asio::datagram_socket_service<boost::asio::ip::udp>::bi nd (this=0x805b0c0, impl=@0xbfbfe2a4, endpoint=@0xbfbfe1a0, ec=@0xbfbfe140) at datagram_socket_service.hpp:145 #4 0x0804c2cd in boost::asio::basic_socket<boost::asio::ip::udp, boost::asio::d atagram_socket_service<boost::asio::ip::udp> >::bind (this=0xbfbfe2a0, endpoint=@0xbfbfe1a0) at basic_socket.hpp:332 #5 0x0804a5fc in receiver (this=0xbfbfe2a0, io_service=@0xbfbfe730, listen_address=@0xbfbfe260, multicast_address=@0xbfbfe280) at receiver.cpp:31 #6 0x08049e44 in main (argc=3, argv=0xbfbfe7a8) at receiver.cpp:84 Alexander Nasonov http://nasonov.blogspot.com By the time we`ve made it, we`ve had it. -- Malcolm Forbes -- This quote is generated by: /usr/pkg/bin/curl -L http://tinyurl.com/veusy \ | sed -e 's/^document\.write(.//' -e 's/.);$/ --/' \ -e 's/<[^>]*>//g' -e 's/^More quotes from //' \ | fmt | tee ~/.signature-quote