diff --git a/components/freertos/port.c b/components/freertos/port.c index 74879e3d5c..9bbff3236e 100644 --- a/components/freertos/port.c +++ b/components/freertos/port.c @@ -90,7 +90,6 @@ // SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -------------------------------------------------------------------------------- */ - #include #include #include diff --git a/components/newlib/platform_include/assert.h b/components/newlib/platform_include/assert.h index 3568727212..d800985b2a 100644 --- a/components/newlib/platform_include/assert.h +++ b/components/newlib/platform_include/assert.h @@ -19,10 +19,12 @@ #pragma once #include #include +#include "esp_compiler.h" #include_next + #if defined(CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT) && !defined(NDEBUG) #undef assert -#define assert(__e) ((__e) ? (void)0 : abort()) +#define assert(__e) (likely(__e)) ? (void)0 : abort() #endif