bug-commoncpp
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

UDPTransmit::connect bug


From: Boris.
Subject: UDPTransmit::connect bug
Date: Wed, 29 Dec 2010 21:33:56 GMT

Hi.

The return code check from setMulticast(...) on the lines 134 and 147 is not 
correct, cConnect(...) is never called and transmit(...) method does not send 
anything because the socket is not connected.

The following is the fragment of fixed version of peer.cpp file:
 
    134 Socket::Error UDPTransmit::connect(const IPV4Multicast &group, tpport_t 
port)
    135 {
    136         Error err;
    137         if( err = UDPSocket::setMulticast(true) )
    138                 return err;
    139 
    140         return cConnect((IPV4Address)group,port);
    141 }
    142 
    143 #ifdef  CCXX_IPV6
    144 Socket::Error UDPTransmit::connect(const IPV6Multicast &group, tpport_t 
port)
    145 {
    146         Error error;
    147         if( error = UDPSocket::setMulticast(true) )
    148                 return error;
    149 
    150         return connect((IPV6Address)group,port);
    151 }
    152 #endif

Thank you.
Boris Falkovsky.



____________________________________________________________
Obama Urges Homeowners to Refinance
If you owe under $729k you probably qualify for Obama's Refi Program
http://thirdpartyoffers.juno.com/TGL3131/4d1ba98f935ca931e33st03vuc



reply via email to

[Prev in Thread] Current Thread [Next in Thread]