diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2007-04-11 11:54:20 +0000 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2007-04-11 11:54:20 +0000 |
commit | eace48730376bae14e561c57ef59fb9e721f94ac (patch) | |
tree | b86a93a22ef3a79b14beebdf9ee1414d9b0c674b /cppe/src | |
parent | fixing start port and server count to be the same as the icee test (diff) | |
download | ice-eace48730376bae14e561c57ef59fb9e721f94ac.tar.bz2 ice-eace48730376bae14e561c57ef59fb9e721f94ac.tar.xz ice-eace48730376bae14e561c57ef59fb9e721f94ac.zip |
Port for gumstix
Diffstat (limited to 'cppe/src')
-rw-r--r-- | cppe/src/IceE/Initialize.cpp | 2 | ||||
-rw-r--r-- | cppe/src/IceE/Network.cpp | 27 |
2 files changed, 1 insertions, 28 deletions
diff --git a/cppe/src/IceE/Initialize.cpp b/cppe/src/IceE/Initialize.cpp index 2ccd9fd426a..1062a289b6f 100644 --- a/cppe/src/IceE/Initialize.cpp +++ b/cppe/src/IceE/Initialize.cpp @@ -120,7 +120,7 @@ CommunicatorPtr Ice::initialize(StringSeq& args, const InitializationData& initializationData, Int version) { int origArgc; - char** argv; + char** argv = 0; CommunicatorPtr communicator; try diff --git a/cppe/src/IceE/Network.cpp b/cppe/src/IceE/Network.cpp index 869db016118..9d0a0da363d 100644 --- a/cppe/src/IceE/Network.cpp +++ b/cppe/src/IceE/Network.cpp @@ -14,8 +14,6 @@ #if defined(_WIN32) # include <winsock2.h> -#elif defined(__linux) || defined(__APPLE__) || defined(__FreeBSD__) -# include <ifaddrs.h> #else # include <sys/ioctl.h> # include <net/if.h> @@ -946,31 +944,6 @@ IceInternal::getLocalHosts() { result.push_back(inetAddrToString(addrs[i].sin_addr)); } -#elif defined(__linux) || defined(__APPLE__) || defined(__FreeBSD__) - struct ifaddrs* ifap; - if(::getifaddrs(&ifap) == SOCKET_ERROR) - { - SocketException ex(__FILE__, __LINE__); - ex.error = getSocketErrno(); - throw ex; - } - - struct ifaddrs* curr = ifap; - while(curr != 0) - { - if(curr->ifa_addr && curr->ifa_addr->sa_family == AF_INET) - { - struct sockaddr_in* addr = reinterpret_cast<struct sockaddr_in*>(curr->ifa_addr); - if(addr->sin_addr.s_addr != 0) - { - result.push_back(inetAddrToString((*addr).sin_addr)); - } - } - - curr = curr->ifa_next; - } - - ::freeifaddrs(ifap); #else SOCKET fd = createSocket(); |