主题:问题: Firefox crash -- truth
除非有人take time to fix the core, mozilla那帮人似乎并不热心. 此bug是mozilla的设计问题, 已有数年历史, 曾被列为won't fix. 现在reopen了, 但fix还是遥遥无期. 怎么IE和Opera就没有这个问题呢?
If Mozilla crashes, then all the images in the cache are lost (and presumably
the cached HTML pages as well). This is easy to reproduce: just go to a site
with a lot of graphics (like http://megatokyo.com), do "killall -9 mozilla-bin",
then restart Mozilla and go back to that site; it will start reloading all of
the images.
This is by design. The cache is primarily an optimization. Rather than add a
bunch of extra code to verify it and fix any potential corruption, we toss it
and start again.
unfortunately, there is no code to detect a bad cache. what mozilla does
currently is detect that the cache was never closed after being previously
opened. what this means simply is that when the cache is opened, a flag is set
indicating that its on disk representation is dirty (i.e., possibly incomplete).
at shutdown everything is sync'd to disk and the dirty flag is cleared.
however, what you are proposing requires determining if a cache is corrupt or
not, and that is a very complicated problem to solve. we are no where close to
having enough support in gecko to determine if the cache files are consistent.
i think you do not understand how the cache is implemented. in a nut-shell (and
this explains why this bug is hard to fix), the index of cache entries is an
in-memory data structure that is only written to disk when the browser exits
cleanly. however, data files are written as we load pages. the result is that
the data files on disk are not in sync (at all) with the index of cache entries
stored on disk. hence, if we do not shutdown cleanly, we do not have a
meaningful index of cache entries on disk.
the "solution" that you propose would cause the browser to crash or load
incorrect content in many cases.
i understand that this bug matters to some people, but so do many other bugs.
fixing this bug is a non-trivial task. if it were a trivial task, we wouldn't
be having this discussion. please try to temper your comments in the future.
getting angry doesn't solve anything.
FYI, we are planning a rewrite of the cache based on SQLite. Part of this
rewrite should solve this bug (hopefully). If you are interested, see the
beginnings of this code here:
http://lxr.mozilla.org/mozilla/source/netwerk/cache/src/nsDiskCacheDeviceSQL.cpp
- 相关回复 上下关系8
🤔问题: Firefox crash truth 字228 2005-06-16 14:38:21
有没有试过session saver,一个插件? 林小筑 字159 2005-06-18 14:15:29
😠看来此问题短期内无解
建议:重装一次 水帘洞主 字124 2005-06-16 18:18:42
🙂并不是经常crash truth 字129 2005-06-17 06:04:35
我感觉Firefox压根就没有升级功能。所谓升级就是将最新的Firefox Highway 字188 2005-06-16 19:02:31
It is a monolithic application now. How can you patch a monolithic 请尽量 字346 2005-06-17 23:14:56
😮Monolithic application, that's not the pattern I would like to use. Highway 字169 2005-06-18 01:03:05