Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8563d11b authored by z00208928's avatar z00208928 Committed by android-build-merger
Browse files

Merge "power: gps: add gps read timeout" into oc-mr1-dev am: 7e22a7ee

am: f8ba3769

Change-Id: Ia5e146a3169e4b430c6a05515dfa90a9896a6d26
parents d140c09d f8ba3769
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -41,6 +41,7 @@ public class GpsXtraDownloader {
    private static final long MAXIMUM_CONTENT_LENGTH_BYTES = 1000000;  // 1MB.
    private static final String DEFAULT_USER_AGENT = "Android";
    private static final int CONNECTION_TIMEOUT_MS = (int) TimeUnit.SECONDS.toMillis(30);
    private static final int READ_TIMEOUT_MS = (int) TimeUnit.SECONDS.toMillis(60);

    private final String[] mXtraServers;
    // to load balance our server requests
@@ -123,6 +124,7 @@ public class GpsXtraDownloader {
                    "x-wap-profile",
                    "http://www.openmobilealliance.org/tech/profiles/UAPROF/ccppschema-20021212#");
            connection.setConnectTimeout(CONNECTION_TIMEOUT_MS);
            connection.setReadTimeout(READ_TIMEOUT_MS);

            connection.connect();
            int statusCode = connection.getResponseCode();