ADB默认端口5037被占用解决办法

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/curry_du/article/details/80511439

Windows平台直接运行下面批处理即可解决问题

@echo off

set flag=False
For /f "tokens=2,5" %%i in ('netstat -ano')  do ( (echo %%i | findstr 127.0.0.1:5037 && if %%j NEQ 0 (
taskkill /F /PID %%j && set flag=True) > nul )
)
if %flag% == True (
echo Process occupying port 5037 is killed successfully!
) else (
echo No process occupying port 5037 is found!

pause
展开阅读全文

没有更多推荐了,返回首页