summaryrefslogtreecommitdiff
path: root/src/mongo/dbtests/querytests.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/dbtests/querytests.cpp')
-rw-r--r--src/mongo/dbtests/querytests.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/mongo/dbtests/querytests.cpp b/src/mongo/dbtests/querytests.cpp
index bab0f1e22fe..5aac0a989e5 100644
--- a/src/mongo/dbtests/querytests.cpp
+++ b/src/mongo/dbtests/querytests.cpp
@@ -216,13 +216,11 @@ namespace QueryTests {
class ClientBase {
public:
ClientBase() : _client(&_txn) {
- _prevError = mongo::lastError._get( false );
- mongo::lastError.release();
- mongo::lastError.reset( new LastError() );
+ mongo::LastError::get(_txn.getClient()).reset();
_txn.getCurOp()->reset();
}
virtual ~ClientBase() {
- mongo::lastError.reset( _prevError );
+ mongo::LastError::get(_txn.getClient()).reset();
}
protected:
@@ -238,9 +236,6 @@ namespace QueryTests {
OperationContextImpl _txn;
DBDirectClient _client;
-
- private:
- LastError* _prevError;
};
class BoundedKey : public ClientBase {