设置socket接收和发送超时的一种方式
摘要:Linux环境设置Socket接收和发送超时:须如下定义:struct timeval timeout = {3,0};//设置发送超时setsockopt(socket,SOL_SOCKET,SO_SNDTIMEO,(char *)&timeout,sizeof(struct timeval));...
阅读全文
posted @ 2015-06-19 21:36
posted @ 2015-06-19 21:36
posted @ 2015-06-05 17:40
posted @ 2013-04-23 13:46