]> git.ipfire.org Git - thirdparty/squid.git/commit
Detail swapfile header inconsistencies.
authorEduard Bagdasaryan <eduard.bagdasaryan@measurement-factory.com>
Fri, 17 Mar 2017 07:44:27 +0000 (20:44 +1300)
committerAmos Jeffries <squid3@treenet.co.nz>
Fri, 17 Mar 2017 07:44:27 +0000 (20:44 +1300)
commit4c2f8b720a6c580ebaf37844ef3fb95ecac8e6eb
tree06d10349d63c655b997a1ee2a743304c581cd46a
parentad9e2efd14b2dc6d308991bed86f160d4e9aa3bb
Detail swapfile header inconsistencies.

Squid may fail to load cache entry metadata for several very different
reasons, including the following two relatively common ones:

* A cache_dir entry corruption.
* Huge cache_dir entry metadata that does not fit into the I/O buffer
  used for loading entry metadata.

Knowing the exact failure reason may help triage and guide development.
We refactored existing checks to distinguish various error cases,
including the two above. Refactoring also reduced code duplication.

These improvements also uncovered and fixed a null pointer dereference
inside ufsdump.cc (but ufsdump does not even build right now for reasons
unrelated to these changes).
src/StoreMetaUnpacker.cc
src/StoreMetaUnpacker.h
src/fs/rock/RockHeaderUpdater.cc
src/store_client.cc
src/store_rebuild.cc
src/ufsdump.cc