Signed-off-by: Alexey Melnikov <aamelnikov@gmail.com>
Signed-off-by: Sam Hartman <hartmans@debian.org>
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25206
dc483132-0cff-0310-8789-
dd5450dbe970
(void) setsockopt(s, SOL_SOCKET, SO_REUSEADDR, (char *) &on, sizeof(on));
if (bind(s, (struct sockaddr *) &saddr, sizeof(saddr)) < 0) {
perror("binding socket");
- (void) close(s);
+ (void) closesocket(s);
return -1;
}
if (listen(s, 5) < 0) {
perror("listening on socket");
- (void) close(s);
+ (void) closesocket(s);
return -1;
}
return s;