diff --git a/TellusAgent.c b/TellusAgent.c index f6bb2ea..e827040 100644 --- a/TellusAgent.c +++ b/TellusAgent.c @@ -17,7 +17,6 @@ #include #include #include -#include #ifdef __linux__ #include @@ -117,9 +116,9 @@ int main(int argc, const char* argv[]) uint16_t proxyPorts[PROXY_PORT_COUNT] = { - htobe16(50000), - htobe16(50001), - htobe16(50002) + htons(50000), + htons(50001), + htons(50002) }; // Start up @@ -263,8 +262,8 @@ int main(int argc, const char* argv[]) proxySocketAddress.sin_port = proxyPorts[selection]; handle = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP); - if((handle < 0) || - (bind(handle, (struct sockaddr*)&proxySocketAddress, proxySocketLength) < 0)) + if ((handle < 0) || + (bind(handle, (struct sockaddr*)&proxySocketAddress, proxySocketLength) < 0)) { print("Error opening port for Multi-Site Connect\n"); return EXIT_FAILURE; @@ -284,8 +283,8 @@ int main(int argc, const char* argv[]) uplinkSocketAddress.sin6_scope_id = 0; uplinkHandle = socket(AF_INET6, SOCK_DGRAM, IPPROTO_UDP); - if((uplinkHandle < 0) || - (bind(uplinkHandle, (struct sockaddr*)&uplinkSocketAddress, sizeof(uplinkSocketAddress)) < 0)) + if ((uplinkHandle < 0) || + (bind(uplinkHandle, (struct sockaddr*)&uplinkSocketAddress, sizeof(uplinkSocketAddress)) < 0)) { print("Error opening port for Rewind Uplink\n"); return EXIT_FAILURE; @@ -389,9 +388,6 @@ int main(int argc, const char* argv[]) memset(outgoingBuffer, 0, sizeof(struct RewindData)); memcpy(outgoingBuffer, REWIND_PROTOCOL_SIGN, REWIND_SIGN_LENGTH); - struct utsname systemName; - uname(&systemName); - struct sockaddr_in repeaterSocketAddresses[3]; memset(repeaterSocketAddresses, 0, sizeof(repeaterSocketAddresses)); diff --git a/Version.h b/Version.h index 49a1ce8..ff2f25e 100644 --- a/Version.h +++ b/Version.h @@ -1 +1 @@ -#define VERSION 20161101 +#define VERSION 20161102