[Ns-bugs] [Bug 244] PacketSink is not multitasking
bugzilla-daemon@nsnam-www.ece.gatech.edu
bugzilla-daemon at nsnam-www.ece.gatech.edu
Fri Jul 11 10:42:48 PDT 2008
http://www.nsnam.org/bugzilla/show_bug.cgi?id=244
------- Comment #10 from raj.b at gatech.edu 2008-07-11 13:42 -------
(In reply to comment #9)
> (In reply to comment #8)
>
> > > I believe that the packet sink is supposed to invoke the rx callback for each
> > > packet received and you don't do that for the 'accepted' sockets. Or, do you ?
> > >
> >
> > I think it should be OK since the HandleRead() method is passed the socket
> > pointer of the socket with data to be read. Of course, should be tested before
> > checkin.
>
> But do you ever connect the HandleRead method to the accepted sockets ? I don't
> think so. i.e., this:
>
> +void PacketSink::HandleAccept (Ptr<Socket> s, const Address& from)
> +{
> + m_socketList.push_back(s);
> +}
>
> needs to somehow connect HandleRead to get read events from that socket.
>
I THINK it is already connected to HandleRead through the way TcpSocketImpl
uses the copy constructor to fork the accepted connection socket, which copies
the callbacks.
I was completely certain it did this before the addition of the extra TcpSocket
class in the Socket->TcpSocket->TcpSocketImpl heirarchy.
As always, I'll have a test to verify.
--
Configure bugmail: http://www.nsnam.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the Ns-bugs
mailing list