You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2022/04/06 18:51:45 UTC
[incubator-nuttx-apps] 01/03: testing/mm: Update after the recent changes in nuttx
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx-apps.git
commit cc5f73019e717102d2bacdeed6a211efa13e70fe
Author: YAMAMOTO Takashi <ya...@midokura.com>
AuthorDate: Wed Apr 6 18:15:05 2022 +0900
testing/mm: Update after the recent changes in nuttx
The following commit changed the typo of SIZEOF_MM_ALLOCNODE
from int to size_t.
```
commit 39eaeefb78f36724adbdc47400d6f60372b68344
Author: Jiuzhu Dong <do...@xiaomi.com>
Date: Thu Jan 27 12:17:20 2022 +0800
mm/mm_heap: remove the unnecessary check for memory node size
Signed-off-by: Jiuzhu Dong <do...@xiaomi.com>
```
---
testing/mm/mm_main.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/testing/mm/mm_main.c b/testing/mm/mm_main.c
index 1ee38e507..0c064e376 100644
--- a/testing/mm/mm_main.c
+++ b/testing/mm/mm_main.c
@@ -351,7 +351,8 @@ static void *realloc_boundary_malloc(int *nodesize)
}
else
{
- printf("malloc failed, size=%d\n", (size << 1) - SIZEOF_MM_ALLOCNODE);
+ printf("malloc failed, size=%zu\n",
+ (size_t)((size << 1) - SIZEOF_MM_ALLOCNODE));
}
return ptr;
@@ -374,7 +375,7 @@ static void realloc_boundary(void)
DEBUGASSERT(sizeof(dq_entry_t) <= (MM_MIN_CHUNK - SIZEOF_MM_ALLOCNODE));
printf("memory realloc_boundary test start.\n");
- printf("MM_MIN_CHUNK=%d, SIZEOF_MM_ALLOCNODE=%d\n",
+ printf("MM_MIN_CHUNK=%d, SIZEOF_MM_ALLOCNODE=%zu\n",
MM_MIN_CHUNK, SIZEOF_MM_ALLOCNODE);
/* Malloc memory until the memeory ran out */