Closed Bug 1034728 Opened 8 years ago Closed 8 years ago
Apps using App
Cache aren't cached if the App Cache is already cached in Firefox
Installing an app that uses AppCache should download the cache in the app's profile directory. This is not happening for apps that use an AppCache that is already downloaded in Firefox. I guess we're checking if the AppCache is already downloaded in general and we're not making the distinction between "already downloaded in the current profile" and "already downloaded in the target profile". The function that takes care of downloading the AppCache for apps is |nsIOfflineCacheUpdate::scheduleAppUpdate|, the last parameter is the target profile. Easily reproducible with this app: http://nell-balloons.github.cscott.net/
(In reply to Marco Castelluccio [:marco] from comment #0) > The function that takes care of downloading the AppCache for apps is > |nsIOfflineCacheUpdate::scheduleAppUpdate|, the last parameter is the target > profile. Exactly, and the update that is scheduled creates always a new app cache in the target directory: http://hg.mozilla.org/mozilla-central/annotate/fc35681b0a87/uriloader/prefetch/nsOfflineCacheUpdate.cpp#l1249 I'll try to reproduce tho.
Cause: - offline cache update channels are set LOAD_CHECK_OFFLINE_CACHE flag - this makes them look into appcache even they are not set "previous appcache" to check on - custom profile appcache loads (=an installable app) are not set the previous cache (correctly) - but the flag makes them do the default browser profile appcache lookup => we check the manifest, it's not changed => no update, no download, no love We can freely remove the flag, since if there is a cache to use as a normal cache for the load it's set manually on the channel: http://hg.mozilla.org/mozilla-central/annotate/6608e0605dfc/uriloader/prefetch/nsOfflineCacheUpdate.cpp#l393 https://treeherder.mozilla.org/#/jobs?repo=try&revision=5d8ca498ef2f
Attachment #8569259 - Flags: review?(jduell.mcbugs)
You need to log in before you can comment on or make changes to this bug.