mirror of https://github.com/mongodb/mongo
SERVER-113374 Add check for empty container to guide Coverity (#44344)
GitOrigin-RevId: e52a5a2c9e0aee02fb063ce580e0075e30354096
This commit is contained in:
parent
124919a10f
commit
58b3064214
|
|
@ -356,6 +356,9 @@ template <typename T>
|
|||
const OverflowPoint<T>& OverflowState<T>::detect(const ControlBlockContainer& controls) {
|
||||
using namespace bsoncolumn::internal;
|
||||
|
||||
// This function must be called with at least one control block
|
||||
invariant(!controls.empty());
|
||||
|
||||
// Setup reverse iteration.
|
||||
auto begin = controls.rbegin();
|
||||
auto it = begin;
|
||||
|
|
|
|||
Loading…
Reference in New Issue