verify database state before calling sqlite. Bug:2593970

Change-Id: Id68365abccbdca572ad13c2b51162d53993ff540
4 files changed