Fix memory leak in cache_test introduced in the previous commit
Test Plan: Verified that valgrind build passes for cache_test Reviewers: igor Reviewed By: igor Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D37665
This commit is contained in:
parent
4961a9622c
commit
3db81d535a
@ -383,6 +383,11 @@ TEST_F(CacheTest, SetCapacity) {
|
||||
cache->SetCapacity(7);
|
||||
ASSERT_EQ(7, cache->GetCapacity());
|
||||
ASSERT_EQ(7, cache->GetUsage());
|
||||
|
||||
// release remaining 5 to keep valgrind happy
|
||||
for (size_t i = 5; i < 10; i++) {
|
||||
cache->Release(handles[i]);
|
||||
}
|
||||
}
|
||||
|
||||
TEST_F(CacheTest, OverCapacity) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user