Hello,
Does anyone know what the effects are of opening a socket, i.e. when
performing a ping, and never closing the socket. My app does this every
minute. Would the app just hang or would it crash or neither.
It is the same socket each time ... I am trying to implement a ping. Here's
the code I use for the socket connection ( it's in C++ and the parameters
are defined in winsock.h ):
socket(AF_INET, SOCK_RAW, IPPROTO_ICMP)
It doesn't return any error and I can see that I'm connecting alot of times
and I have since corrected this. But I'm wondering if the crashes and hangs
I have been having in my app is because of this. Would opening
hundreds of sockets cause the system to get bouged down ( take up
system resources ) or even crash the app??
Thanks