[MacOS] accept() prototyping.

From: Dean Takemori (dean@UHHEPH.PHYS.HAWAII.EDU)
Date: 07/05/98


So I spent some time downgrading to CodeWarrior Pro2 in order to
evaluate Circle 3.0bPL14 on MacOS.  It compiles pretty much
out-of-the-box, needing only some tweaks to the conf.h.mac and
about five #ifdef lines elsewhere.  A patch is forthcoming as
soon as the following is resolved.

There seems to be some confusion regarding the accept() parameters.

  if ((desc = accept(s, (struct sockaddr *) &peer, &i)) == INVALID_SOCKET) {

The problem is that i is an unsigned int, where the accept prototypes
available under Solaris 2.4, Digital Unix 3.2, the MacOS GUSI sockets
library 1.8.4 and even the prototype provided by Circle in sysdep.h
all indicate that the third parameter to accept should be an int*,
not an unsigned int*.

Are there any systems in which accept() requires an unsigned int*?
If so, this probably should be tested in the configure script,
and the dependance built into a #ifdef'ed typedef.

If not, this is a bug.

     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |

This archive was generated by hypermail 2b30 : 12/15/00 PST