简体   繁体   English

Lua:原始套接字

[英]Lua: Raw Sockets

I'm trying to get sockets to work on a port that's already in use. 我正在尝试让套接字在已经使用的端口上工作。

I know LuaSocket--however I can not get LuaSocket to work on a local port that's already in use. 我知道LuaSocket,但是我无法让LuaSocket在已经使用的本地端口上工作。

Thanks 谢谢

You can't. 你不能 Ports cannot have multiple sockets open there. 端口不能在那里打开多个插座。

As Puppy said, this is impossible. 正如小狗所说,这是不可能的。

But, depending on what exactly you want to archive, there might be other solutions. 但是,根据您要确切归档的内容,可能还有其他解决方案。 Is this the server or a client? 这是服务器还是客户端?

Maybe you can interrupt one socket to give the other time to do his work, or so? 也许您可以打扰一个插座,让另一个时间来完成工作,等等?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM