Index: src/OFDate.m ================================================================== --- src/OFDate.m +++ src/OFDate.m @@ -12,11 +12,11 @@ * Public License, either version 2 or 3, which can be found in the file * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ -#define _POSIX_SOURCE +#define _POSIX_C_SOURCE 199309L #define _XOPEN_SOURCE 500 #include "config.h" #include Index: src/OFThread.m ================================================================== --- src/OFThread.m +++ src/OFThread.m @@ -13,12 +13,11 @@ * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #define OF_THREAD_M -#define _POSIX_C_SOURCE 199309 -#define _POSIX_TIMERS +#define _POSIX_C_SOURCE 199309L #define __NO_EXT_QNX #include "config.h" #include Index: tests/OFHTTPClientTests.m ================================================================== --- tests/OFHTTPClientTests.m +++ tests/OFHTTPClientTests.m @@ -14,13 +14,11 @@ * file. */ #include "config.h" -#include #include -#include #import "OFHTTPClient.h" #import "OFHTTPRequest.h" #import "OFHTTPResponse.h" #import "OFString.h" @@ -38,11 +36,11 @@ static OFCondition *cond; @interface OFHTTPClientTestsServer: OFThread { @public - uint16_t port; + uint16_t _port; } @end @implementation OFHTTPClientTestsServer - main @@ -50,12 +48,12 @@ OFTCPSocket *listener, *client; [cond lock]; listener = [OFTCPSocket socket]; - port = [listener bindToHost: @"127.0.0.1" - port: 0]; + _port = [listener bindToHost: @"127.0.0.1" + port: 0]; [listener listen]; [cond signal]; [cond unlock]; @@ -63,11 +61,11 @@ if (![[client readLine] isEqual: @"GET /foo HTTP/1.1"]) OF_ENSURE(0); if (![[client readLine] isEqual: - [OFString stringWithFormat: @"Host: 127.0.0.1:%" @PRIu16, port]]) + [OFString stringWithFormat: @"Host: 127.0.0.1:%" @PRIu16, _port]]) OF_ENSURE(0); if (![[client readLine] hasPrefix: @"User-Agent:"]) OF_ENSURE(0); @@ -105,11 +103,11 @@ [cond wait]; [cond unlock]; url = [OFURL URLWithString: [OFString stringWithFormat: @"http://127.0.0.1:%" @PRIu16 "/foo", - server->port]]; + server->_port]]; TEST(@"-[performRequest:]", (client = [OFHTTPClient client]) && R(request = [OFHTTPRequest requestWithURL: url]) && R(response = [client performRequest: request]))