diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2016-04-14 08:48:59 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2016-04-15 12:21:46 +0200 |
commit | 01f8f60cf06e180b2b5eb96ceb162473c0cb196a (patch) | |
tree | b792cbe498d9143e263704f7ce3fa79031790bdf /lib | |
parent | 70bbeea7b227866bdbdef0b249ff7f8644713f15 (diff) | |
download | barebox-01f8f60cf06e180b2b5eb96ceb162473c0cb196a.tar.gz barebox-01f8f60cf06e180b2b5eb96ceb162473c0cb196a.tar.xz |
stdio: rename getc to getchar
The function we have implemented as getc has the semantics of the
standard function getchar, so rename it accorgingly.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/readkey.c | 8 | ||||
-rw-r--r-- | lib/readline_simple.c | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/lib/readkey.c b/lib/readkey.c index 2073a732f4..2870a5a9fe 100644 --- a/lib/readkey.c +++ b/lib/readkey.c @@ -53,15 +53,15 @@ int read_key(void) { char c; char esc[5]; - c = getc(); + c = getchar(); if (c == 27) { int i = 0; - esc[i++] = getc(); - esc[i++] = getc(); + esc[i++] = getchar(); + esc[i++] = getchar(); if (isdigit(esc[1])) { while(1) { - esc[i] = getc(); + esc[i] = getchar(); if (esc[i++] == '~') break; if (i == ARRAY_SIZE(esc)) diff --git a/lib/readline_simple.c b/lib/readline_simple.c index 1a40d113e3..c2960665fb 100644 --- a/lib/readline_simple.c +++ b/lib/readline_simple.c @@ -70,7 +70,7 @@ int readline (const char *prompt, char *line, int len) show_activity(0); } #endif - c = getc(); + c = getchar(); /* * Special character handling |