Fix a compile problem noted by Marco Cruz

This commit is contained in:
Gregory Nutt 2014-10-13 12:07:40 -06:00
parent 74d8218618
commit dd9e42ec0c

View file

@ -263,9 +263,13 @@ int elf_load(FAR struct elf_loadinfo_s *loadinfo)
elf_elfsize(loadinfo);
/* Determine the heapsize to allocate */
/* Determine the heapsize to allocate. heapsize is ignored if there is
* no address environment.
*/
#ifdef CONFIG_ARCH_STACK_DYNAMIC
#if !defined(CONFIG_ARCH_ADDRENV)
heapsize = 0;
#elif defined(CONFIG_ARCH_STACK_DYNAMIC)
heapsize = ARCH_HEAP_SIZE;
#else
heapsize = MIN(ARCH_HEAP_SIZE, CONFIG_ELF_STACKSIZE);