summaryrefslogtreecommitdiff
path: root/src/mongo/bson/bsonobj.cpp
diff options
context:
space:
mode:
authorGabriel Russell <gabriel.russell@mongodb.com>2020-02-13 11:49:46 -0500
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-02-13 18:16:35 +0000
commita84c09a19720b73cedb2e8ef7c5cfeedfa1c9761 (patch)
tree85ac46cd5f4ea6d5134560bf764fb9e6cf11fe4e /src/mongo/bson/bsonobj.cpp
parent6df40e01f7b6899affc4536e7e73a35802cabf98 (diff)
downloadmongo-a84c09a19720b73cedb2e8ef7c5cfeedfa1c9761.tar.gz
SERVER-45869 automatically converted structured logging
Diffstat (limited to 'src/mongo/bson/bsonobj.cpp')
-rw-r--r--src/mongo/bson/bsonobj.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mongo/bson/bsonobj.cpp b/src/mongo/bson/bsonobj.cpp
index 994cbde6070..dc37c075b5a 100644
--- a/src/mongo/bson/bsonobj.cpp
+++ b/src/mongo/bson/bsonobj.cpp
@@ -120,8 +120,11 @@ BSONObj BSONObj::copy() const {
// that the memory we are reading has changed, and we must exit immediately to avoid further
// undefined behavior.
if (int sizeAfter = objsize(); sizeAfter != size) {
- severe() << "BSONObj::copy() - size " << sizeAfter
- << " differs from previously observed size " << size;
+ LOGV2_FATAL(
+ 20103,
+ "BSONObj::copy() - size {sizeAfter} differs from previously observed size {size}",
+ "sizeAfter"_attr = sizeAfter,
+ "size"_attr = size);
fassertFailed(31323);
}
memcpy(storage.get(), objdata(), size);