adb forward remote port to local machine

后端 未结 2 1529
野趣味
野趣味 2020-12-23 16:25

This is a query regarding the usage of adb on android.

Is there a way to forward the remote port i.e. port on the android device/emulator to the local machine to whi

2条回答
  •  悲哀的现实
    2020-12-23 17:17

    Do you truly need to forward the port or are you just looking for a way to communicate using sockets from a program running on the android shell to your host machine? I was able to accomplish the latter by sending my message to the port of interest on "10.0.2.2", which is the loopback adapter of the host machine. See docs here.

    EDIT
    This is the updated link

提交回复
热议问题