关于CAsyncSocket的问题 [英] Question about CAsyncSocket

查看:128
本文介绍了关于CAsyncSocket的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨.

CAsyncSocket出现了一个奇怪的问题.如果我连接到服务器并且没有执行发送"之类的操作,则似乎无法成功连接,因为我认为站在我这一边,我不会发送"SYNC"之类的信息.这似乎是在我不直接控制的TCPIP协议的较低层中发送的.我是否缺少套接字本身的某些设置?如果我打电话给发送",那就可以了.如果没有,我将被切断.

不知道是否有人有类似的东西.

提前谢谢.

Stan the man

Hi.

I got a strange issue with CAsyncSocket. If I connect to a server and I do not do a "send" or something, I can not seem to connect successfully because I think on my side, I will not send a "SYNC" or something. THis seems to be something that is sent in the lower layers of the TCPIP protocol which I do not control directly. Am I missing some setting for the socket itself? If I do a call to "Send", then it is OK. If not, I will just get cut off.

Dont know if anyone had had anything similar.

Thanks in advance.

Stan the man

推荐答案

您可能正在寻找SO_KEEPALIVE

http://msdn.microsoft.com/en-us/library/1s9cycf8 (v = vs.71).aspx [
You might be looking for SO_KEEPALIVE

http://msdn.microsoft.com/en-us/library/1s9cycf8(v=vs.71).aspx[^]


这篇关于关于CAsyncSocket的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆