Fix commit 3b75814945 where sometimes collection is not saved

This commit is contained in:
Ai Lin Chia
2017-06-14 11:58:58 +02:00
parent 7f1553b3b3
commit 9105c58d22

@ -324,6 +324,8 @@ bool Collectiondb::addNewColl ( const char *coll,
// point to this, so Rdb and RdbBase can reference it
coll = cr->m_coll;
cr->setNeedsSave();
//
// BEGIN NEW CODE
//
@ -488,6 +490,8 @@ bool Collectiondb::deleteRec2 ( collnum_t collnum ) {
log(LOG_INFO,"db: deleting coll \"%s\" (%" PRId32")",coll,
(int32_t)cr->m_collnum);
cr->setNeedsSave();
// CAUTION: tree might be in the middle of saving
// we deal with this in Process.cpp now