Attempted fix for systems where sizeof(int) < sizeof(void*)

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@21770 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-Macdonald 2005-10-04 11:54:03 +00:00
parent 839793e442
commit 32da350755
7 changed files with 43 additions and 28 deletions

View file

@ -1794,7 +1794,7 @@ static unsigned wordAlign;
- (void) getFds: (int*)fds count: (int*)count
{
NSMapEnumerator me;
WSAEVENT event;
void *event;
SOCKET fd;
GSTcpHandle *handle;
id recvSelf;
@ -1822,7 +1822,7 @@ static unsigned wordAlign;
*/
recvSelf = GS_GC_HIDE(self);
me = NSEnumerateMapTable(events);
while (NSNextMapEnumeratorPair(&me, (void*)&event, (void*)&fd))
while (NSNextMapEnumeratorPair(&me, &event, (void**)&fd))
{
handle = (GSTcpHandle*)NSMapGet(handles, (void*)(gsaddr)fd);
if (handle->recvPort == recvSelf && handle->inReplyMode == NO)
@ -1837,7 +1837,7 @@ static unsigned wordAlign;
- (void) getFds: (int*)fds count: (int*)count
{
NSMapEnumerator me;
SOCKET sock;
void *sock;
GSTcpHandle *handle;
id recvSelf;
@ -1864,11 +1864,11 @@ static unsigned wordAlign;
*/
recvSelf = GS_GC_HIDE(self);
me = NSEnumerateMapTable(handles);
while (NSNextMapEnumeratorPair(&me, (void*)&sock, (void*)&handle))
while (NSNextMapEnumeratorPair(&me, &sock, (void**)&handle))
{
if (handle->recvPort == recvSelf)
{
fds[(*count)++] = sock;
fds[(*count)++] = (SOCKET)sock;
}
}
NSEndMapTableEnumeration(&me);
@ -1879,7 +1879,7 @@ static unsigned wordAlign;
- (id) conversation: (NSPort*)recvPort
{
NSMapEnumerator me;
SOCKET sock;
void *dummy;
GSTcpHandle *handle = nil;
M_LOCK(myLock);
@ -1887,7 +1887,7 @@ static unsigned wordAlign;
* Enumerate all our socket handles, and look for one with port.
*/
me = NSEnumerateMapTable(handles);
while (NSNextMapEnumeratorPair(&me, (void*)&sock, (void*)&handle))
while (NSNextMapEnumeratorPair(&me, &dummy, (void**)&handle))
{
if ([handle recvPort] == recvPort)
{
@ -1907,6 +1907,7 @@ static unsigned wordAlign;
{
NSMapEnumerator me;
SOCKET sock;
void *dummy;
#ifndef BROKEN_SO_REUSEADDR
int opt = 1;
#endif
@ -1917,7 +1918,7 @@ static unsigned wordAlign;
* Enumerate all our socket handles, and look for one with port.
*/
me = NSEnumerateMapTable(handles);
while (NSNextMapEnumeratorPair(&me, (void*)&sock, (void*)&handle))
while (NSNextMapEnumeratorPair(&me, &dummy, (void**)&handle))
{
if ([handle recvPort] == recvPort)
{