会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
孤独的程序员dis1500
知识就是希望
2020年8月2日
socket发送接收数据
摘要: 1.先发送长度 2.按长度接收数据
阅读全文
posted @ 2020-08-02 14:25 lydstory
阅读(157)
评论(0)
推荐(0)
linger
摘要: 某些具体程序要求待未发送完的数据发送出去后再关闭socket,可通过设置让程序满足要求: struct linger { u_short l_onoff; u_short l_linger; }; struct linger m_sLinger; m_sLinger.l_onoff = 1; //在
阅读全文
posted @ 2020-08-02 12:20 lydstory
阅读(338)
评论(0)
推荐(0)
导航
博客园
首页
新随笔
联系
订阅
管理
公告