summaryrefslogtreecommitdiffstats
path: root/otherlibs/win32unix/accept.c
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>2006-10-18 08:26:54 +0000
committerXavier Leroy <xavier.leroy@inria.fr>2006-10-18 08:26:54 +0000
commit4af5727d181e7a77b358751202246382d8aefba6 (patch)
tree799fb5078428bb524da81f9a7f8169bddd8856fd /otherlibs/win32unix/accept.c
parent35d863e204eb61c4d7c1b141e6c6b9a4172dceb0 (diff)
PR#4097: suite
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@7697 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'otherlibs/win32unix/accept.c')
-rw-r--r--otherlibs/win32unix/accept.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/otherlibs/win32unix/accept.c b/otherlibs/win32unix/accept.c
index 0e44f5800..05fd731e5 100644
--- a/otherlibs/win32unix/accept.c
+++ b/otherlibs/win32unix/accept.c
@@ -29,7 +29,7 @@ CAMLprim value unix_accept(sock)
int oldvalue, oldvaluelen, newvalue, retcode;
union sock_addr_union addr;
socklen_param_type addr_len;
- DWORD errcode = 0;
+ DWORD err = 0;
oldvaluelen = sizeof(oldvalue);
retcode = getsockopt(INVALID_SOCKET, SOL_SOCKET, SO_OPENTYPE,
@@ -43,7 +43,7 @@ CAMLprim value unix_accept(sock)
addr_len = sizeof(sock_addr);
enter_blocking_section();
snew = accept(sconn, &addr.s_gen, &addr_len);
- if (snew == INVALID_SOCKET) errcode = WSAGetLastError ();
+ if (snew == INVALID_SOCKET) err = WSAGetLastError ();
leave_blocking_section();
if (retcode == 0) {
/* Restore initial mode */
@@ -51,7 +51,7 @@ CAMLprim value unix_accept(sock)
(char *) &oldvalue, oldvaluelen);
}
if (snew == INVALID_SOCKET) {
- win32_maperr(errcode);
+ win32_maperr(err);
uerror("accept", Nothing);
}
Begin_roots2 (fd, adr)