I have got an application that uses sockets (UDP). In this case I have
got to use "bind" to connect. Anyway, the second parameter is a sockaddr
struct. Using a cast it works rigth for me.
struct sockaddr_in direc_pda;
bind(sockfd, (struct sockaddr *) &direc_pda, sizeof(direc_pda));
I hope this be useful.