Tokyo Cabinet internal coherence checking code