comparison src/w32.c @ 63038:ac1cd1222417

(sys_setsockopt): Change arg 4 to `const void *'. In the call to pfn_setsockopt, cast optval to `const char *'.
author Eli Zaretskii <eliz@gnu.org>
date Sun, 05 Jun 2005 19:13:37 +0000
parents 92ecd695d7c1
children 19486c46b17e 01137c1fdbe9
comparison
equal deleted inserted replaced
63037:e7db86688ce6 63038:ac1cd1222417
3205 h_errno = ENOTSOCK; 3205 h_errno = ENOTSOCK;
3206 return SOCKET_ERROR; 3206 return SOCKET_ERROR;
3207 } 3207 }
3208 3208
3209 int 3209 int
3210 sys_setsockopt (int s, int level, int optname, const char * optval, int optlen) 3210 sys_setsockopt (int s, int level, int optname, const void * optval, int optlen)
3211 { 3211 {
3212 if (winsock_lib == NULL) 3212 if (winsock_lib == NULL)
3213 { 3213 {
3214 h_errno = ENETDOWN; 3214 h_errno = ENETDOWN;
3215 return SOCKET_ERROR; 3215 return SOCKET_ERROR;
3217 3217
3218 check_errno (); 3218 check_errno ();
3219 if (fd_info[s].flags & FILE_SOCKET) 3219 if (fd_info[s].flags & FILE_SOCKET)
3220 { 3220 {
3221 int rc = pfn_setsockopt (SOCK_HANDLE (s), level, optname, 3221 int rc = pfn_setsockopt (SOCK_HANDLE (s), level, optname,
3222 optval, optlen); 3222 (const char *)optval, optlen);
3223 if (rc == SOCKET_ERROR) 3223 if (rc == SOCKET_ERROR)
3224 set_errno (); 3224 set_errno ();
3225 return rc; 3225 return rc;
3226 } 3226 }
3227 h_errno = ENOTSOCK; 3227 h_errno = ENOTSOCK;