Applied Ian Wienand's patches (4-2-2004). Was partly applied earlier.

This commit is contained in:
likewise
2004-02-16 21:33:42 +00:00
parent f75da2c393
commit 7bfea6edb7
7 changed files with 24 additions and 18 deletions

View File

@@ -292,7 +292,7 @@ mem_malloc(mem_size_t size)
}
sys_sem_signal(mem_sem);
LWIP_ASSERT("mem_malloc: allocated memory not above ram_end.",
(u32_t)mem + SIZEOF_STRUCT_MEM + size <= (u32_t)ram_end);
(mem_ptr_t)mem + SIZEOF_STRUCT_MEM + size <= (mem_ptr_t)ram_end);
LWIP_ASSERT("mem_malloc: allocated memory properly aligned.",
(unsigned long)((u8_t *)mem + SIZEOF_STRUCT_MEM) % MEM_ALIGNMENT == 0);
return (u8_t *)mem + SIZEOF_STRUCT_MEM;