]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
DeterministicOpSequence: add 'ceph_asserts()' where we expect != NULL.
authorJoao Eduardo Luis <jecluis@gmail.com>
Wed, 25 Apr 2012 15:27:41 +0000 (16:27 +0100)
committerJoao Eduardo Luis <jecluis@gmail.com>
Wed, 25 Apr 2012 15:27:41 +0000 (16:27 +0100)
Signed-off-by: Joao Eduardo Luis <jecluis@gmail.com>
src/test/filestore/DeterministicOpSequence.cc

index 70c7e91b1f630a5ac2d24504bc0ef52da4106b0c..fd28713059d5399007d73d0f46c0416d9664271f 100644 (file)
@@ -142,6 +142,7 @@ void DeterministicOpSequence::do_touch(rngen_t& gen)
   int obj_id = _gen_obj_id(gen);
 
   coll_entry_t *entry = get_coll_at(coll_id);
+  ceph_assert(entry != NULL);
   hobject_t *obj = entry->touch_obj(obj_id);
 
   dout(0) << "do_touch " << entry->m_coll.to_str() << "/" << obj->oid.name << dendl;
@@ -155,6 +156,7 @@ void DeterministicOpSequence::do_remove(rngen_t& gen)
   int obj_id = _gen_obj_id(gen);
 
   coll_entry_t *entry = get_coll_at(coll_id);
+  ceph_assert(entry != NULL);
   hobject_t *obj = entry->touch_obj(obj_id);
 
   // ENOENT ok here.