[Linux] AudioRelay shows all available IPs, but only listens on one


AudioRelay server on PC shows all the available IPs but only listens on one of them. Client cannot connect to other local IP.

netstat output when client tries to connect through

flopster101@FLOP-ENDLNX ~ $ netstat -putan | grep java
tcp6       0      0 :::59100                :::*                    LISTEN      1371076/java        
tcp6       0      0      ESTABLISHED 1371076/java        
tcp6       0      0    ESTABLISHED 1371076/java        
udp6       0      0 :::35638                :::*                                1371076/java        
udp6       0      0 :::48694                :::*                                1371076/java

I am able to ping both IPs, and I can connect to just fine.

Steps to reproduce

1- Be connected to Wi-Fi and Ethernet on the same network (example).
2- Start AudioRelay as server on PC.
3- Try to connect through phone. In my case, the found server fails to connect because the phone tries the IP that doesn’t work.
4- Try to connect through the other IP manually. Works fine.

1- Close AudioRelay server.
2- Disable one of the network interfaces and reopen AudioRelay server.
3- It will now listen on the next interface correctly and the phone will find the correct IP to connect.


Device A (Server):
Linux (EndeavourOS)
AudioRelay 0.27.5

Device B (Client):
Android 14
AudioRelay 0.26.1


flopster101@FLOP-ENDLNX ~ $ audiorelay
2024-05-19 17:32:23:886 [INFO] Version: 0.27.5, os: Linux, osVersion: 6.9.1-2-cachyos
2024-05-19 17:32:24:207 [INFO] Initializing locale to en
2024-05-19 17:32:24:314 [INFO] Network addresses: NetworkInfo(broadcastAddresses=[,,,], localAdd
2024-05-19 17:32:24:328 [INFO] Starting the server...
2024-05-19 17:32:24:339 [INFO] Waiting for devices from RtAudio…
2024-05-19 17:32:24:450 [INFO] Checking for update...
2024-05-19 17:32:24:986 [INFO] Showing main window...
2024-05-19 17:32:25:009 [INFO] Rendering api: OPENGL
2024-05-19 17:32:25:617 [INFO] Found no update
2024-05-19 17:32:28:535 [INFO] Remote device connected:
2024-05-19 17:32:28:557 [INFO] Received client config, clientVersion: 0.26.1, os: ANDROID, osVersion: Android API 34
The reported device's input latency is 0 or unavailable
2024-05-19 17:32:29:084 [INFO] Audio pipeline is emitting values