-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Internal Code
-
Fully Compatible
-
ALL
-
-
Platforms 13 (04/22/16)
If there is no OpObserver in the global service context, the call may invoke a method through a nullptr:
src/mongo/db/catalog/database.cpp:532:5: runtime error: member call on null pointer of type 'mongo::OpObserver' #0 0x11fa893 in mongo::Database::createCollection(mongo::OperationContext*, mongo::StringData, mongo::CollectionOptions const&, bool) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/db/catalog/database.cpp:532:5 #1 0x1562be6 in mongo::update(mongo::OperationContext*, mongo::Database*, mongo::UpdateRequest const&, mongo::OpDebug*) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/db/ops/update.cpp:99:26 #2 0x13384c0 in mongo::Helpers::putSingleton(mongo::OperationContext*, char const*, mongo::BSONObj) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/db/dbhelpers.cpp:259:5 #3 0x17d25cc in mongo::repl::setMinValid(mongo::OperationContext*, mongo::repl::BatchBoundaries const&) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/db/repl/minvalid.cpp:109:9 #4 0x100fd1a in (anonymous namespace)::RSRollbackTest::setUp() /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/db/repl/rs_rollback_test.cpp:164:5 #5 0x1db5163 in mongo::unittest::Test::run() /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest.cpp:140:5 #6 0x10304e0 in void mongo::unittest::Suite::runTestObject<(anonymous namespace)::UnitTest__RSRollbackTest__InconsistentMinValid>() /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest.h:405:9 #7 0x1db693d in mongo::unittest::TestHolder::run() const /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest.h:257:9 #8 0x1db693d in mongo::unittest::Suite::run(std::string const&, int) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest.cpp:263 #9 0x1db7e07 in mongo::unittest::Suite::run(std::vector<std::string, std::allocator<std::string> > const&, std::string const&, int) /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest.cpp:321:27 #10 0x1dbd0f7 in main /home/andrew/Documents/10gen/dev/src/mongodb/src/mongo/unittest/unittest_main.cpp:40:12 #11 0x7ff47331ba3f in __libc_start_main /build/buildd/glibc-2.21/csu/libc-start.c:289 #12 0xff70d8 in _start (/home/andrew/Documents/10gen/dev/src/mongodb/build/optdebug/mongo/db/repl/rs_rollback_test+0xff70d8)
This was detected in a unit test, so this may only be an issue when running the tests.