Commit 391b1978 authored by Carlos Falgueras García's avatar Carlos Falgueras García Committed by David Brown
Browse files

bootutil: Only include <os/malloc.h> if it going to be used



When no dynamic memory is used, there is no need for include "os/malloc.h",
and do so will force the user to create an empty "os/malloc.h" file.

Signed-off-by: default avatarCarlos Falgueras García <carlos.falgueras@wslw.es>
parent 8787bb04
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -35,7 +35,6 @@
#include <inttypes.h>
#include <stdlib.h>
#include <string.h>
#include <os/os_malloc.h>
#include "bootutil/bootutil.h"
#include "bootutil/image.h"
#include "bootutil_priv.h"
@@ -50,6 +49,10 @@
#include "bootutil/enc_key.h"
#endif

#if !defined(MCUBOOT_DIRECT_XIP) && !defined(MCUBOOT_RAM_LOAD)
#include <os/os_malloc.h>
#endif

#include "mcuboot_config/mcuboot_config.h"

BOOT_LOG_MODULE_DECLARE(mcuboot);