Skip to content

Commit cde0db2

Browse files
erreinaMongoDB Bot
authored andcommitted
SERVER-101322 Fix uninitialized cmp variable (#33080)
GitOrigin-RevId: 301d1d08e8d59c8d5917c4bbe11103086835f862
1 parent 54c95df commit cde0db2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/mongo/db/storage/wiredtiger/wiredtiger_record_store.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -837,7 +837,7 @@ void WiredTigerRecordStore::reclaimOplog(OperationContext* opCtx) {
837837
// between records, the truncate marker check is not sufficient.
838838
CursorKey truncateUpToKey = makeCursorKey(truncateMarker->lastRecord, _keyFormat);
839839
setKey(cursor, &truncateUpToKey);
840-
int cmp;
840+
int cmp = 0;
841841
ret = wiredTigerPrepareConflictRetry(opCtx,
842842
[&] { return cursor->search_near(cursor, &cmp); });
843843
invariantWTOK(ret, cursor->session);

0 commit comments

Comments
 (0)