diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-05-19 09:13:24 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-05-19 09:13:24 +0000 |
commit | 5e1249af266c9688ec575e5a2f14ecfe6084de49 (patch) | |
tree | caa2477037b299f92860d734bf2750987478c8e4 /test | |
parent | 807c5f1882224c2afd471a44889b83c2adf80589 (diff) | |
download | ChibiOS-5e1249af266c9688ec575e5a2f14ecfe6084de49.tar.gz ChibiOS-5e1249af266c9688ec575e5a2f14ecfe6084de49.tar.bz2 ChibiOS-5e1249af266c9688ec575e5a2f14ecfe6084de49.zip |
Fixed bug 3303841.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2973 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'test')
-rw-r--r-- | test/testdyn.c | 14 | ||||
-rw-r--r-- | test/testheap.c | 4 |
2 files changed, 10 insertions, 8 deletions
diff --git a/test/testdyn.c b/test/testdyn.c index 5657a8dc2..d015e2ac6 100644 --- a/test/testdyn.c +++ b/test/testdyn.c @@ -54,7 +54,7 @@ */
#if CH_USE_DYNAMIC || defined(__DOXYGEN__)
-#if CH_USE_HEAP || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__)
static MemoryHeap heap1;
#endif
#if CH_USE_MEMPOOLS || defined(__DOXYGEN__)
@@ -78,7 +78,7 @@ static msg_t thread(void *p) { return 0;
}
-#if CH_USE_HEAP || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__)
static void dyn1_setup(void) {
chHeapInit(&heap1, test.buffer, sizeof(union test_buffers));
@@ -124,7 +124,7 @@ ROMCONST struct testcase testdyn1 = { NULL,
dyn1_execute
};
-#endif /* CH_USE_HEAP */
+#endif /* (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) */
#if CH_USE_MEMPOOLS || defined(__DOXYGEN__)
/**
@@ -182,7 +182,8 @@ ROMCONST struct testcase testdyn2 = { };
#endif /* CH_USE_MEMPOOLS */
-#if (CH_USE_HEAP && CH_USE_REGISTRY) || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP && CH_USE_REGISTRY) || \
+ defined(__DOXYGEN__)
/**
* @page test_dynamic_003 Registry and References test
*
@@ -252,13 +253,14 @@ ROMCONST struct testcase testdyn3 = { */
ROMCONST struct testcase * ROMCONST patterndyn[] = {
#if CH_USE_DYNAMIC || defined(__DOXYGEN__)
-#if CH_USE_HEAP || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__)
&testdyn1,
#endif
#if CH_USE_MEMPOOLS || defined(__DOXYGEN__)
&testdyn2,
#endif
-#if (CH_USE_HEAP && CH_USE_REGISTRY) || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP && CH_USE_REGISTRY) || \
+ defined(__DOXYGEN__)
&testdyn3,
#endif
#endif
diff --git a/test/testheap.c b/test/testheap.c index bfdcea1e6..6316b56c6 100644 --- a/test/testheap.c +++ b/test/testheap.c @@ -48,7 +48,7 @@ * @brief Heap header file
*/
-#if CH_USE_HEAP || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__)
#define SIZE 16
@@ -156,7 +156,7 @@ ROMCONST struct testcase testheap1 = { * @brief Test sequence for heap.
*/
ROMCONST struct testcase * ROMCONST patternheap[] = {
-#if CH_USE_HEAP || defined(__DOXYGEN__)
+#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__)
&testheap1,
#endif
NULL
|