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

Commit e3958be4 authored by Gustav Sennton's avatar Gustav Sennton Committed by android-build-merger
Browse files

Merge "Allow disk reads during more parts of WebView loading." into nyc-dev

am: c48b082d

* commit 'c48b082d':
  Allow disk reads during more parts of WebView loading.
parents a249556f c48b082d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -262,11 +262,11 @@ public final class WebViewFactory {
                        "For security reasons, WebView is not allowed in privileged processes");
            }

            StrictMode.ThreadPolicy oldPolicy = StrictMode.allowThreadDiskReads();
            Trace.traceBegin(Trace.TRACE_TAG_WEBVIEW, "WebViewFactory.getProvider()");
            try {
                Class<WebViewFactoryProvider> providerClass = getProviderClass();

                StrictMode.ThreadPolicy oldPolicy = StrictMode.allowThreadDiskReads();
                Trace.traceBegin(Trace.TRACE_TAG_WEBVIEW, "providerClass.newInstance()");
                try {
                    sProviderInstance = providerClass.getConstructor(WebViewDelegate.class)
@@ -278,10 +278,10 @@ public final class WebViewFactory {
                    throw new AndroidRuntimeException(e);
                } finally {
                    Trace.traceEnd(Trace.TRACE_TAG_WEBVIEW);
                    StrictMode.setThreadPolicy(oldPolicy);
                }
            } finally {
                Trace.traceEnd(Trace.TRACE_TAG_WEBVIEW);
                StrictMode.setThreadPolicy(oldPolicy);
            }
        }
    }