Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix implicit function declaration warnings in error.c by including string.h #3866

Closed
noonfom opened this issue Nov 9, 2020 · 0 comments · Fixed by #3867
Closed

Fix implicit function declaration warnings in error.c by including string.h #3866

noonfom opened this issue Nov 9, 2020 · 0 comments · Fixed by #3867
Assignees
Labels
bug component-platform Portability layer and build scripts

Comments

@noonfom
Copy link

noonfom commented Nov 9, 2020

Description

Compiling mbed-os-6.4.0 results in warnings about implicit declarations of memset and strlen in error.c on lines 224 and 581, respectively. This is because string.h is not included in the source file. Actually, the include for string.h is embedded in a conditional compilation directive on line 28: string.h will be included if the MBEDTLS_ERROR_STRERROR_DUMMY macro is defined. However, the MBEDTLS_ERROR_STRERROR_DUMMY macro is not defined.

@gilles-peskine-arm gilles-peskine-arm added bug component-platform Portability layer and build scripts Product Backlog labels Nov 9, 2020
@gilles-peskine-arm gilles-peskine-arm self-assigned this Nov 9, 2020
gilles-peskine-arm added a commit to gilles-peskine-arm/mbedtls that referenced this issue Nov 9, 2020
<string.h> is actually needed when MBEDTLS_ERROR_C is enabled and not
when only MBEDTLS_ERROR_STRERROR_DUMMY is enabled.

Fix Mbed-TLS#3866.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug component-platform Portability layer and build scripts
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants