Python论坛  - 讨论区

标题:[python-chinese] 问个SOCKET的问题

2007年05月28日 星期一 23:33

散漫酷男孩 17mxnet在gmail.com
星期一 五月 28 23:33:22 HKT 2007

客户端发送数据大小不一定
服务端
socket recv接收数据怎么接收特别大的数据呢?

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 03:45

Samuel Chi princeofdatamining在gmail.com
星期二 五月 29 03:45:12 HKT 2007

·¢Ë͵ÄʱºòÇ°Ãæ¼ÓÉÏmessageµÄ³¤¶È£¬½âÎöµÄʱºòÏÈÄÃmessageµÄ³¤¶È£¬Èç¹ûdataµÄ³¤¶È²»¹»Ôòbuffer¼ÓÉÏеÄdata£¬Ö±µ½bufferµÄ³¤¶È´ïµ½messageµÄ³¤¶È£¬ÔòÌá³ömessage£¬²¢½âÎöÖ®¡«

ÔÚ07-5-28£¬É¢Âþ¿áÄк¢ <17mxnet在gmail.com> дµÀ£º
>
> ¿Í»§¶Ë·¢ËÍÊý¾Ý´óС²»Ò»¶¨
> ·þÎñ¶Ë
> socket recv½ÓÊÕÊý¾ÝÔõô½ÓÊÕÌØ±ð´óµÄÊý¾ÝÄØ£¿
> _______________________________________________
> python-chinese
> Post: send python-chinese在lists.python.cn
> Subscribe: send subscribe to python-chinese-request在lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request在lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
-------------- 下一部分 --------------
Ò»¸öHTML¸½¼þ±»ÒƳý...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/a04bc758/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 13:34

Eiwot eiwot在hotmail.com
星期二 五月 29 13:34:25 HKT 2007

Hi all,
   I created a new Python resource blog at http://pyarticles.blogspot.com . Let's check it out. Any comments are welcome :)
 
Cheers 
_________________________________________________________________
Change is good. See what’s different about Windows Live Hotmail. 
http://www.windowslive-hotmail.com/learnmore/default.html?locale=en-us&ocid;=RMT_TAGLM_HMWL_reten_changegood_0507
-------------- 下一部分 --------------
??HTML?????...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/db9d5360/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 14:15

散漫酷男孩 17mxnet在gmail.com
星期二 五月 29 14:15:10 HKT 2007

恩 我现在在前4字节中存储长度
然后再读后面的长度
每次读取的长度最大有限制吗?


在 07-5-29,Samuel Chi<princeofdatamining在gmail.com> 写道:
> 发送的时候前面加上message的长度,解析的时候先拿message的长度,如果data的长度不够则buffer加上新的data,直到buffer的长度达到message的长度,则提出message,并解析之~
>
> 在07-5-28,散漫酷男孩 < 17mxnet在gmail.com> 写道:
> > 客户端发送数据大小不一定
> > 服务端
> > socket recv接收数据怎么接收特别大的数据呢?
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese在lists.python.cn
> > Subscribe: send subscribe to
> python-chinese-request在lists.python.cn
> > Unsubscribe: send unsubscribe to
> python-chinese-request在lists.python.cn
> > Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
>
>
> _______________________________________________
> python-chinese
> Post: send python-chinese在lists.python.cn
> Subscribe: send subscribe to
> python-chinese-request在lists.python.cn
> Unsubscribe: send unsubscribe to
> python-chinese-request在lists.python.cn
> Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
>

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 15:49

jessinio smith jessinio在gmail.com
星期二 五月 29 15:49:32 HKT 2007

´ò²»¿ªÑ½~£¡~£¡~£¡~ÀÏ´ó
-------------- 下一部分 --------------
Ò»¸öHTML¸½¼þ±»ÒƳý...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/55b97ad8/attachment.htm 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 15:56

kun yao how.i.wish.how.i.wish.you.were.here在gmail.com
星期二 五月 29 15:56:16 HKT 2007

我北京电信,正常,博主坚持更新。

2007/5/29, jessinio smith <jessinio在gmail.com>:
>
> 打不开呀~!~!~!~老大
>
> _______________________________________________
> python-chinese
> Post: send python-chinese在lists.python.cn
> Subscribe: send subscribe to python-chinese-request在lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request在lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>



-- 
Keep it simple,stupid.
-------------- 下一部分 --------------
一个HTML附件被移除...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/920f64aa/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 17:40

frank su corelito在gmail.com
星期二 五月 29 17:40:34 HKT 2007

Ã²ËÆ google µÄblogspot£¬¹úÄÚ´ò²»¿ª°É

2007/5/29, Eiwot <eiwot在hotmail.com>:
>
>  Hi all,
>    I created a new Python resource blog at http://pyarticles.blogspot.com. Let's check it out. Any comments are welcome :)
>
> Cheers
>
> ------------------------------
> Change is good. See what's different about Windows Live Hotmail. Check it
> out!<http://www.windowslive-hotmail.com/learnmore/default.html?locale=en-us&ocid;=RMT_TAGLM_HMWL_reten_changegood_0507%0A%0A>
>
> _______________________________________________
> python-chinese
> Post: send python-chinese在lists.python.cn
> Subscribe: send subscribe to python-chinese-request在lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request在lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
-------------- 下一部分 --------------
Ò»¸öHTML¸½¼þ±»ÒƳý...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/b334d6c5/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 18:35

Samuel Chi princeofdatamining在gmail.com
星期二 五月 29 18:35:39 HKT 2007

ÎÞÐë¹Ø×¢·¢ËͺͶÁÈ¡µÄ×î´ó³¤¶È¡£
buffer³õʼΪ''£¬ÓжÁÈ¡µ½ÄÚÈݾÍbuffer+=message
ÏÈÅжÏbufferÊÇ·ñ³¬¹ý4byte£¬³¬¹ýµÄ»°¼ÆËã³öÐèÒª½âÎöµÄ³¤¶Èparselen£¬
È»ºó±È½ÏbufferÊÇ·ñ×ã¹»parselen³¤£¬¹»µÄ»°È¡³öÐÅÏ¢²¢´ÓbufferÖÐÈ¥µô£¬
²»¹»µÄ»°£¬µÈ´ýÏ´ÎÊý¾ÝµÄ½ÓÊÕ£¡

ÔÚ07-5-29£¬É¢Âþ¿áÄк¢ <17mxnet在gmail.com> дµÀ£º
>
> ¶÷ ÎÒÏÖÔÚÔÚǰ4×Ö½ÚÖд洢³¤¶È
> È»ºóÔÙ¶ÁºóÃæµÄ³¤¶È
> ÿ´Î¶ÁÈ¡µÄ³¤¶È×î´óÓÐÏÞÖÆÂð£¿
>
>
> ÔÚ 07-5-29£¬Samuel Chi<princeofdatamining在gmail.com> дµÀ£º
> >
> ·¢Ë͵ÄʱºòÇ°Ãæ¼ÓÉÏmessageµÄ³¤¶È£¬½âÎöµÄʱºòÏÈÄÃmessageµÄ³¤¶È£¬Èç¹ûdataµÄ³¤¶È²»¹»Ôòbuffer¼ÓÉÏеÄdata£¬Ö±µ½bufferµÄ³¤¶È´ïµ½messageµÄ³¤¶È£¬ÔòÌá³ömessage£¬²¢½âÎöÖ®¡«
> >
> > ÔÚ07-5-28£¬É¢Âþ¿áÄк¢ < 17mxnet在gmail.com> дµÀ£º
> > > ¿Í»§¶Ë·¢ËÍÊý¾Ý´óС²»Ò»¶¨
> > > ·þÎñ¶Ë
> > > socket recv½ÓÊÕÊý¾ÝÔõô½ÓÊÕÌØ±ð´óµÄÊý¾ÝÄØ£¿
> > > _______________________________________________
> > > python-chinese
> > > Post: send python-chinese在lists.python.cn
> > > Subscribe: send subscribe to
> > python-chinese-request在lists.python.cn
> > > Unsubscribe: send unsubscribe to
> > python-chinese-request在lists.python.cn
> > > Detail Info:
> > http://python.cn/mailman/listinfo/python-chinese
> >
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese在lists.python.cn
> > Subscribe: send subscribe to
> > python-chinese-request在lists.python.cn
> > Unsubscribe: send unsubscribe to
> > python-chinese-request在lists.python.cn
> > Detail Info:
> > http://python.cn/mailman/listinfo/python-chinese
> >
> _______________________________________________
> python-chinese
> Post: send python-chinese在lists.python.cn
> Subscribe: send subscribe to python-chinese-request在lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request在lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
-------------- 下一部分 --------------
Ò»¸öHTML¸½¼þ±»ÒƳý...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/0b05553c/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 20:39

黄毅 yi.codeplayer在gmail.com
星期二 五月 29 20:39:48 HKT 2007

>
> 貌似 google 的blogspot,国内打不开吧


我是教育网,也可以访问。
虽然被封过几次,基本上很长时间都正常了。

-- 
http://codeplayer.blogspot.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/97bb7c87/attachment.html 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2007年05月29日 星期二 20:43

黄毅 yi.codeplayer在gmail.com
星期二 五月 29 20:43:51 HKT 2007

我也推荐个资源,每周一个python模块。
http://www.doughellmann.com/projects/PyMOTW/


On 5/29/07, Eiwot <eiwot at hotmail.com> wrote:
>
> Hi all,
>    I created a new Python resource blog at http://pyarticles.blogspot.com. Let's check it out. Any comments are welcome :)
>
> Cheers
>
> ------------------------------
> Change is good. See what's different about Windows Live Hotmail. Check it
> out!<http://www.windowslive-hotmail.com/learnmore/default.html?locale=en-us&ocid;=RMT_TAGLM_HMWL_reten_changegood_0507%0A%0A>
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>



-- 
http://codeplayer.blogspot.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://python.cn/pipermail/python-chinese/attachments/20070529/58717acc/attachment.htm 

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

如下红色区域有误,请重新填写。

    你的回复:

    请 登录 后回复。还没有在Zeuux哲思注册吗?现在 注册 !

    Zeuux © 2025

    京ICP备05028076号