mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2025-07-20 03:23:07 +00:00
Loosen the connection timeouts. Remove the HTTP request timeout because it depends on how long it takes for the requested app to start.
This commit is contained in:
parent
022866288d
commit
0fe7549942
@ -15,7 +15,7 @@ public class NvControl implements ConnectionStatusListener {
|
||||
|
||||
public static final int PORT = 47995;
|
||||
|
||||
public static final int CONTROL_TIMEOUT = 3000;
|
||||
public static final int CONTROL_TIMEOUT = 5000;
|
||||
|
||||
public static final short PTYPE_HELLO = 0x1204;
|
||||
public static final short PPAYLEN_HELLO = 0x0004;
|
||||
|
@ -18,8 +18,7 @@ public class NvHTTP {
|
||||
|
||||
public static final int PORT = 47989;
|
||||
|
||||
public static final int CONNECTION_TIMEOUT = 3000;
|
||||
public static final int REQUEST_TIMEOUT = 15000;
|
||||
public static final int CONNECTION_TIMEOUT = 5000;
|
||||
|
||||
|
||||
public String baseUrl;
|
||||
@ -63,7 +62,6 @@ public class NvHTTP {
|
||||
URLConnection conn = new URL(url).openConnection();
|
||||
conn.setConnectTimeout(CONNECTION_TIMEOUT);
|
||||
conn.setDefaultUseCaches(false);
|
||||
conn.setReadTimeout(REQUEST_TIMEOUT);
|
||||
conn.connect();
|
||||
return conn.getInputStream();
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ import java.net.Socket;
|
||||
public class NvHandshake {
|
||||
public static final int PORT = 47991;
|
||||
|
||||
public static final int HANDSHAKE_TIMEOUT = 3000;
|
||||
public static final int HANDSHAKE_TIMEOUT = 5000;
|
||||
|
||||
public static final byte[] PLATFORM_HELLO =
|
||||
{
|
||||
|
@ -29,7 +29,7 @@ public class NvVideoStream {
|
||||
public static final int RTCP_PORT = 47999;
|
||||
public static final int FIRST_FRAME_PORT = 47996;
|
||||
|
||||
public static final int FIRST_FRAME_TIMEOUT = 3000;
|
||||
public static final int FIRST_FRAME_TIMEOUT = 5000;
|
||||
|
||||
private ArrayBlockingQueue<AvRtpPacket> packets = new ArrayBlockingQueue<AvRtpPacket>(100);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user