1
0
mirror of https://github.com/irssi/irssi.git synced 2024-12-04 14:46:39 -05:00

Remove unneeded casts.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4647 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Emanuele Giaquinta 2007-11-20 13:34:45 +00:00 committed by exg
parent 66080034ee
commit 474699f14d

View File

@ -182,10 +182,8 @@ GIOChannel *net_connect_ip(IPADDR *ip, int port, IPADDR *my_ip)
#ifndef WIN32
fcntl(handle, F_SETFL, O_NONBLOCK);
#endif
setsockopt(handle, SOL_SOCKET, SO_REUSEADDR,
(char *) &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_KEEPALIVE,
(char *) &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_KEEPALIVE, &opt, sizeof(opt));
/* set our own address */
if (my_ip != NULL) {
@ -293,10 +291,8 @@ GIOChannel *net_listen(IPADDR *my_ip, int *port)
#ifndef WIN32
fcntl(handle, F_SETFL, O_NONBLOCK);
#endif
setsockopt(handle, SOL_SOCKET, SO_REUSEADDR,
(char *) &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_KEEPALIVE,
(char *) &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt));
setsockopt(handle, SOL_SOCKET, SO_KEEPALIVE, &opt, sizeof(opt));
/* specify the address/port we want to listen in */
ret = bind(handle, &so.sa, SIZEOF_SOCKADDR(so));