]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
osdc/Journaler: validate header on load and save
authorJohn Spray <john.spray@redhat.com>
Thu, 17 Jul 2014 12:15:10 +0000 (13:15 +0100)
committerJohn Spray <john.spray@redhat.com>
Fri, 18 Jul 2014 17:40:51 +0000 (18:40 +0100)
commited3bc4c385a227895cd4d487960d374ee4e60f2d
treee3f47dd61d58d29c4edbe878ae4e75a10935e1d4
parent18ca6b60d1c0a94f81b5936d31bfb3f70add9d17
osdc/Journaler: validate header on load and save

Previously if the journal header contained invalid
write, expire or trimmed offsets, we would end up
hitting a hard-to-understand assertion much later.

Instead, raise the error right away if the fields
are identifiably bad at load time, and assert that
they're valid before persisting them.

Signed-off-by: John Spray <john.spray@redhat.com>
src/osdc/Journaler.cc