Lines 330-340
Link Here
|
330 |
break; |
330 |
break; |
331 |
case SCTP_ADDR_MADE_PRIM : |
331 |
case SCTP_ADDR_MADE_PRIM : |
332 |
event = sun_nio_ch_sctp_PeerAddrChange_SCTP_ADDR_MADE_PRIM; |
332 |
event = sun_nio_ch_sctp_PeerAddrChange_SCTP_ADDR_MADE_PRIM; |
333 |
#ifdef __linux__ /* Solaris currently doesn't support SCTP_ADDR_CONFIRMED */ |
333 |
#ifndef __solaris__ /* Solaris currently doesn't support SCTP_ADDR_CONFIRMED */ |
334 |
break; |
334 |
break; |
335 |
case SCTP_ADDR_CONFIRMED : |
335 |
case SCTP_ADDR_CONFIRMED : |
336 |
event = sun_nio_ch_sctp_PeerAddrChange_SCTP_ADDR_CONFIRMED; |
336 |
event = sun_nio_ch_sctp_PeerAddrChange_SCTP_ADDR_CONFIRMED; |
337 |
#endif /* __linux__ */ |
337 |
#endif /* __solaris__ */ |
338 |
} |
338 |
} |
339 |
|
339 |
|
340 |
addressObj = SockAddrToInetSocketAddress(env, (struct sockaddr*)&spc->spc_aaddr); |
340 |
addressObj = SockAddrToInetSocketAddress(env, (struct sockaddr*)&spc->spc_aaddr); |
Lines 445-457
Link Here
|
445 |
} else if (errno == EINTR) { |
445 |
} else if (errno == EINTR) { |
446 |
return IOS_INTERRUPTED; |
446 |
return IOS_INTERRUPTED; |
447 |
|
447 |
|
448 |
#ifdef __linux__ |
448 |
#ifndef __solaris__ |
449 |
} else if (errno == ENOTCONN) { |
449 |
} else if (errno == ENOTCONN) { |
450 |
/* ENOTCONN when EOF reached */ |
450 |
/* ENOTCONN when EOF reached */ |
451 |
rv = 0; |
451 |
rv = 0; |
452 |
/* there will be no control data */ |
452 |
/* there will be no control data */ |
453 |
msg->msg_controllen = 0; |
453 |
msg->msg_controllen = 0; |
454 |
#endif /* __linux__ */ |
454 |
#endif /* __solaris__ */ |
455 |
|
455 |
|
456 |
} else { |
456 |
} else { |
457 |
handleSocketError(env, errno); |
457 |
handleSocketError(env, errno); |
Lines 568-574
Link Here
|
568 |
/* Set up the msghdr structure for sending */ |
568 |
/* Set up the msghdr structure for sending */ |
569 |
memset(msg, 0, sizeof (*msg)); |
569 |
memset(msg, 0, sizeof (*msg)); |
570 |
memset(cbuf, 0, cbuf_size); |
570 |
memset(cbuf, 0, cbuf_size); |
571 |
msg->msg_name = &sa; |
571 |
msg->msg_name = (sa_len == 0 ? NULL : &sa); |
572 |
msg->msg_namelen = sa_len; |
572 |
msg->msg_namelen = sa_len; |
573 |
iov->iov_base = addr; |
573 |
iov->iov_base = addr; |
574 |
iov->iov_len = length; |
574 |
iov->iov_len = length; |