diff options
Diffstat (limited to 'ghc/lib/misc/cbits/recvFrom.c')
-rw-r--r-- | ghc/lib/misc/cbits/recvFrom.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/ghc/lib/misc/cbits/recvFrom.c b/ghc/lib/misc/cbits/recvFrom.c deleted file mode 100644 index c12c1b0c49..0000000000 --- a/ghc/lib/misc/cbits/recvFrom.c +++ /dev/null @@ -1,31 +0,0 @@ -/* ----------------------------------------------------------------------------- - * $Id: recvFrom.c,v 1.3 1998/12/02 13:26:46 simonm Exp $ - * - * recvFrom run-time support - * - * (c) The GHC Team 1998 - * -------------------------------------------------------------------------- */ - -#define NON_POSIX_SOURCE -#include "Rts.h" -#include "ghcSockets.h" -#include "stgio.h" - -StgInt -recvFrom__(StgInt fd, StgAddr buf, StgInt nbytes, StgAddr from) -{ - StgInt count; - int sz; - int flags = 0; - - sz = sizeof(struct sockaddr_in); - - while ( (count = recvfrom((int)fd, (void*)buf, (int)nbytes, flags, (struct sockaddr*)from, &sz)) < 0) { - if (errno != EINTR) { - cvtErrno(); - stdErrno(); - return -1; - } - } - return count; -} |