mirror of
https://github.com/ETLCPP/etl.git
synced 2026-04-30 19:09:10 +08:00
Fixed non-initialisation of in_use flag.
This commit is contained in:
parent
c7ee1d6574
commit
dceb56dd1a
@ -133,6 +133,27 @@ namespace
|
||||
}
|
||||
}
|
||||
|
||||
//*************************************************************************
|
||||
TEST(test_clear)
|
||||
{
|
||||
BD bd(&buffers[0][0]);
|
||||
BD::descriptor desc[4];
|
||||
|
||||
for (size_t i = 0U; i < N_BUFFERS; ++i)
|
||||
{
|
||||
desc[i] = bd.allocate();
|
||||
}
|
||||
|
||||
bd.clear();
|
||||
|
||||
for (size_t i = 0U; i < N_BUFFERS; ++i)
|
||||
{
|
||||
CHECK(desc[i].is_valid());
|
||||
CHECK(!desc[i].is_allocated());
|
||||
CHECK(desc[i].is_released());
|
||||
}
|
||||
}
|
||||
|
||||
//*************************************************************************
|
||||
TEST(test_buffers_with_allocate_fill)
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user