summaryrefslogtreecommitdiff
path: root/src/mongo/db/db.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/db.cpp')
-rw-r--r--src/mongo/db/db.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/db/db.cpp b/src/mongo/db/db.cpp
index 93408e92a23..c4fb3221ff5 100644
--- a/src/mongo/db/db.cpp
+++ b/src/mongo/db/db.cpp
@@ -320,7 +320,7 @@ namespace mongo {
fassert( 17401, repairDatabase( &txn, dbName ) );
}
- void checkForIdIndexes( Database* db ) {
+ void checkForIdIndexes( OperationContext* txn, Database* db ) {
if ( db->name() == "local") {
// we do not need an _id index on anything in the local database
@@ -337,7 +337,7 @@ namespace mongo {
if ( ns.isSystem() )
continue;
- Collection* coll = db->getCollection( collectionName );
+ Collection* coll = db->getCollection( txn, collectionName );
if ( !coll )
continue;
@@ -373,7 +373,7 @@ namespace mongo {
if (repl::replSettings.usingReplSets()) {
// we only care about the _id index if we are in a replset
- checkForIdIndexes(ctx.db());
+ checkForIdIndexes(&txn, ctx.db());
}
if (shouldClearNonLocalTmpCollections || dbName == "local")
@@ -412,7 +412,7 @@ namespace mongo {
}
else {
const string systemIndexes = ctx.db()->name() + ".system.indexes";
- Collection* coll = ctx.db()->getCollection( systemIndexes );
+ Collection* coll = ctx.db()->getCollection( &txn, systemIndexes );
auto_ptr<Runner> runner(InternalPlanner::collectionScan(systemIndexes,coll));
BSONObj index;
Runner::RunnerState state;