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

Commit 811665e9 authored by Iain Merrick's avatar Iain Merrick
Browse files

*Don't* disable CacheManager when using Chromium HTTP stack.

This reverts CL https://android-git.corp.google.com/g/84508

After lengthy discussion we have decided that disabling CacheManager
is too risky for third-party apps, and that enough functionality is
still available for it to be useful.

WebView.loadUrl() will not add pages to the cache, but it is still
possible to add them manually via CacheManager.saveCacheFile().

Change-Id: I6cfd9f93bb8d685450f048375adad9d17fa4eeba
parent d09bcafb
Loading
Loading
Loading
Loading
+0 −9
Original line number Diff line number Diff line
@@ -181,11 +181,6 @@ public final class CacheManager {
            removeAllCacheFiles();
            mClearCacheOnInit = false;
        }
        // If we're using the Chrome HTTP stack, disable the cache.
        // Chrome has its own cache, and we don't provide programmatic access to it.
        if (JniUtil.useChromiumHttpStack()) {
            setCacheDisabled(true);
        }
    }
    
    /**
@@ -238,10 +233,6 @@ public final class CacheManager {
        if (mDisabled) {
            removeAllCacheFiles();
        }
        if (!mDisabled && JniUtil.useChromiumHttpStack()) {
            Log.w(LOGTAG, "CacheManager enabled, but it will not work as "
                    + "expected because the Chrome HTTP stack is in use.");
        }
    }

    /**