diff options
author | Tor Lillqvist <tlillqvist@suse.com> | 2012-12-18 12:04:55 +0200 |
---|---|---|
committer | Tor Lillqvist <tlillqvist@suse.com> | 2012-12-18 12:11:04 +0200 |
commit | c0e21788c1c9b98493b41a0020f660f4fa5983f3 (patch) | |
tree | ef4abc0e27d93da91654f240774624256bc97ffe /sd/source/ui/remotecontrol | |
parent | 687138f72c607e02f9dabf0ca6c936209e4c76b7 (diff) |
Store some (sadly ignored) return values in variables to make debugging easier...
Diffstat (limited to 'sd/source/ui/remotecontrol')
-rw-r--r-- | sd/source/ui/remotecontrol/DiscoveryService.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sd/source/ui/remotecontrol/DiscoveryService.cxx b/sd/source/ui/remotecontrol/DiscoveryService.cxx index 65420627434f..9d8efa380aad 100644 --- a/sd/source/ui/remotecontrol/DiscoveryService.cxx +++ b/sd/source/ui/remotecontrol/DiscoveryService.cxx @@ -38,6 +38,8 @@ using namespace sd; DiscoveryService::DiscoveryService() : mSocket(0) { + int rc; + mSocket = socket( AF_INET, SOCK_DGRAM, IPPROTO_UDP ); sockaddr_in aAddr; @@ -45,14 +47,14 @@ DiscoveryService::DiscoveryService() : aAddr.sin_addr.s_addr = htonl(INADDR_ANY); aAddr.sin_port = htons( PORT_DISCOVERY ); - bind( mSocket, (sockaddr*) &aAddr, sizeof(sockaddr_in) ); + rc = bind( mSocket, (sockaddr*) &aAddr, sizeof(sockaddr_in) ); struct ip_mreq multicastRequest; multicastRequest.imr_multiaddr.s_addr = inet_addr( "239.0.0.1" ); multicastRequest.imr_interface.s_addr = htonl(INADDR_ANY); - setsockopt( mSocket, IPPROTO_IP, IP_ADD_MEMBERSHIP, + rc = setsockopt( mSocket, IPPROTO_IP, IP_ADD_MEMBERSHIP, #ifdef WNT (const char*) #endif |