summaryrefslogtreecommitdiff
path: root/src/mongo/db/client.cpp
diff options
context:
space:
mode:
authorKristina <kristina@10gen.com>2012-12-28 11:24:47 -0500
committerKristina <kristina@10gen.com>2012-12-28 11:29:34 -0500
commit56944b0240ae4bce795e728f5decd21f2b09be88 (patch)
tree8cbfb8236d61a1e8bac4b81047820c2399979d0d /src/mongo/db/client.cpp
parent11ef57e23acfbf079d4b74055413ba9631e63dc0 (diff)
downloadmongo-56944b0240ae4bce795e728f5decd21f2b09be88.tar.gz
SERVER-8044 Don't delete curop while clientsMutex is held
Diffstat (limited to 'src/mongo/db/client.cpp')
-rw-r--r--src/mongo/db/client.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mongo/db/client.cpp b/src/mongo/db/client.cpp
index ddb342a7b92..3956ae00480 100644
--- a/src/mongo/db/client.cpp
+++ b/src/mongo/db/client.cpp
@@ -165,9 +165,11 @@ namespace mongo {
if ( ! inShutdown() ) {
// we can't clean up safely once we're in shutdown
- scoped_lock bl(clientsMutex);
- if ( ! _shutdown )
- clients.erase(this);
+ {
+ scoped_lock bl(clientsMutex);
+ if ( ! _shutdown )
+ clients.erase(this);
+ }
delete _curOp;
}
}