From e6c4c63c00d9f398f56236639fe6413f6b9cce7f Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Fri, 5 Jun 2020 15:52:01 +0200 Subject: [PATCH] Update post-11 code for #813 --- src/allocator/linked_list.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/allocator/linked_list.rs b/src/allocator/linked_list.rs index c2d1958d..f7164113 100644 --- a/src/allocator/linked_list.rs +++ b/src/allocator/linked_list.rs @@ -45,7 +45,7 @@ impl LinkedListAllocator { /// Adds the given memory region to the front of the list. unsafe fn add_free_region(&mut self, addr: usize, size: usize) { // ensure that the freed region is capable of holding ListNode - assert!(align_up(addr, mem::align_of::()) == addr); + assert_eq!(align_up(addr, mem::align_of::()), addr); assert!(size >= mem::size_of::()); // create a new list node and append it at the start of the list