diff options
author | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2020-10-07 18:11:48 +0200 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-10-22 09:54:53 -0400 |
commit | c670aeee3df9186902dba07b76bd2de0776df390 (patch) | |
tree | 8e61521f5bd9d6e01af762785307ad7c84d91c43 /include | |
parent | 8d5d97cb28bf2ac1e0d7e4b24620c56f3fe45e6f (diff) | |
download | u-boot-c670aeee3df9186902dba07b76bd2de0776df390.tar.gz |
common: rename getc() to getchar()
The sandbox is built with the SDL2 library with invokes the X11 library
which in turn calls getc(). But getc() in glibc is defined as
int getc(FILE *)
This does not match our definition.
int getc(void)
The sandbox crashes when called with parameter -l.
Rename our library symbol getc() to getchar().
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/_exports.h | 2 | ||||
-rw-r--r-- | include/stdio.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/include/_exports.h b/include/_exports.h index 1e9ba86108..aeb666c847 100644 --- a/include/_exports.h +++ b/include/_exports.h @@ -8,7 +8,7 @@ #define EXPORT_FUNC(a, b, c, ...) #endif EXPORT_FUNC(get_version, unsigned long, get_version, void) - EXPORT_FUNC(getc, int, getc, void) + EXPORT_FUNC(getchar, int, getc, void) EXPORT_FUNC(tstc, int, tstc, void) EXPORT_FUNC(putc, void, putc, const char) EXPORT_FUNC(puts, void, puts, const char *) diff --git a/include/stdio.h b/include/stdio.h index aedf374452..039f7df689 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -5,7 +5,7 @@ #include <linux/compiler.h> /* stdin */ -int getc(void); +int getchar(void); int tstc(void); /* stdout */ |