From 6c8e652aa6b5bf7018ff74473a6ef5bb58e4890e Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 16 Jul 2001 17:24:48 -0300 Subject: use macros for 'getc' --- liolib.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'liolib.c') diff --git a/liolib.c b/liolib.c index 81d3e05b..942e9388 100644 --- a/liolib.c +++ b/liolib.c @@ -1,5 +1,5 @@ /* -** $Id: liolib.c,v 1.118 2001/07/12 14:59:14 roberto Exp roberto $ +** $Id: liolib.c,v 1.119 2001/07/12 18:11:58 roberto Exp roberto $ ** Standard I/O (and system) library ** See Copyright Notice in lua.h */ @@ -237,7 +237,7 @@ static int read_until (lua_State *L, FILE *f, const l_char *p, int pl) { luaL_buffinit(L, &b); prep_read_until(next, p, pl); j = 0; - while ((c = fgetc(f)) != EOF) { + while ((c = getc(f)) != EOF) { NoRead: if (c == p[j]) { j++; /* go to next char in pattern */ @@ -272,7 +272,7 @@ static int read_number (lua_State *L, FILE *f) { static int test_eof (lua_State *L, FILE *f) { - l_charint c = fgetc(f); + l_charint c = getc(f); ungetc(c, f); lua_pushlstring(L, NULL, 0); return (c != EOF); -- cgit v1.2.3-55-g6feb