summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--db/dbhelpers.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/db/dbhelpers.cpp b/db/dbhelpers.cpp
index 205787e16c4..2d5b378ecb3 100644
--- a/db/dbhelpers.cpp
+++ b/db/dbhelpers.cpp
@@ -303,6 +303,7 @@ namespace mongo {
if ( yield && ! cc->yieldSometimes() ){
// cursor got finished by someone else, so we're done
+ cc.release(); // if the collection/db is dropped, cc may be deleted
break;
}
}