Skip to content

Commit 99d40fe

Browse files
committed
[libc] Fix freelist_heap_test.cpp warnings
1 parent 3173a4f commit 99d40fe

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

libc/test/src/__support/freelist_heap_test.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ TEST(LlvmLibcFreeListHeap, ReturnsNullWhenFull) {
100100
FreeListHeap allocator(buf);
101101

102102
bool went_null = false;
103-
for (int i = 0; i < N; i++) {
103+
for (size_t i = 0; i < N; i++) {
104104
if (!allocator.allocate(1)) {
105105
went_null = true;
106106
break;
@@ -246,7 +246,6 @@ TEST_FOR_EACH_ALLOCATOR(AlignedAlloc, 2048) {
246246
// still get aligned allocations even if the underlying buffer is not aligned to
247247
// the alignments we request.
248248
TEST(LlvmLibcFreeListHeap, AlignedAllocUnalignedBuffer) {
249-
constexpr size_t BUFFER_SIZE = 4096;
250249
byte buf[4096] = {byte(0)};
251250

252251
// Ensure the underlying buffer is poorly aligned.

0 commit comments

Comments
 (0)