Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

反转C-S后,内网环境下,远程调试连接不上 #169

Open
lc1995 opened this issue Jul 17, 2023 · 1 comment
Open

反转C-S后,内网环境下,远程调试连接不上 #169

lc1995 opened this issue Jul 17, 2023 · 1 comment

Comments

@lc1995
Copy link

lc1995 commented Jul 17, 2023

PC环境下使用VSCode作为Client。
手机(安卓IOS都试过)开启Server,listeningTimeoutSec = 0.5。
手机log里应该是正常开启端口的监听了。
image
VSCode开始调试后,会尝试连接,然后失败断开连接。
image

在PC下Ping手机连的IP(Wifi)是Ping的通的,所以目前不是很能定位到是什么问题。

@stuartwang
Copy link
Collaborator

反转cs后,手机作为server , vscode作为client.
reGetSock success 输出表示luasocket库被成功加载了
image

看起来是luasocket的accept失败了,可能是超时。可以考虑把 listeningTimeoutSec 大点,比如1甚至2,让调试器在accept上等的更久。同时按下面链接的说法改一下server:settimeout(2) ,延长luasocket accept等待时间试下。以下代码在luapanda.lua中,可以直接修改
image

https://stackoverflow.com/questions/42445423/luasocket-serveraccept-timeout-tcp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants