mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
use errno.h for thread safety
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33028 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
b2649e0526
commit
ae8059e5c1
4 changed files with 5 additions and 10 deletions
|
@ -2022,7 +2022,6 @@ NSString * const GSSOCKSRecvAddr = @"GSSOCKSRecvAddr";
|
|||
if (operation == GSFileHandleConnectCompletionNotification
|
||||
|| operation == GSSOCKSConnect)
|
||||
{ // Connection attempt completed.
|
||||
extern int errno;
|
||||
int result;
|
||||
int rval;
|
||||
unsigned len = sizeof(result);
|
||||
|
|
|
@ -62,6 +62,8 @@
|
|||
#include <sys/socket.h> // For MSG_PEEK, etc
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
/*
|
||||
* Implement map keys for strings with case insensitive comparisons,
|
||||
* so we can have case insensitive matching of http headers (correct
|
||||
|
@ -1323,7 +1325,6 @@ static void debugWrite(GSHTTPURLHandle *handle, NSData *data)
|
|||
}
|
||||
if (fd >= 0)
|
||||
{
|
||||
extern int errno;
|
||||
int result;
|
||||
unsigned char c;
|
||||
|
||||
|
@ -1438,11 +1439,6 @@ static void debugWrite(GSHTTPURLHandle *handle, NSData *data)
|
|||
}
|
||||
if (sock == nil)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
extern int __declspec(dllimport) errno;
|
||||
#else
|
||||
extern int errno;
|
||||
#endif
|
||||
/*
|
||||
* Tell superclass that the load failed - let it do housekeeping.
|
||||
*/
|
||||
|
|
|
@ -48,8 +48,7 @@
|
|||
#include "../GSPortPrivate.h"
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
extern __declspec(dllimport) int errno;
|
||||
#include <errno.h>
|
||||
|
||||
#define UNISTR(X) \
|
||||
((const unichar*)[(X) cStringUsingEncoding: NSUnicodeStringEncoding])
|
||||
|
|
|
@ -42,13 +42,14 @@
|
|||
|
||||
#include "GNUstepBase/GSMime.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#include "../GSPrivate.h"
|
||||
#include "../GSPortPrivate.h"
|
||||
|
||||
#define UNISTR(X) \
|
||||
((const unichar*)[(X) cStringUsingEncoding: NSUnicodeStringEncoding])
|
||||
|
||||
extern __declspec(dllimport) int errno;
|
||||
|
||||
static NSRecursiveLock *serverLock = nil;
|
||||
static NSMessagePortNameServer *defaultServer = nil;
|
||||
|
|
Loading…
Reference in a new issue