Fix capture crashing on non inited db (issue #124)