From 6a6ae6e1a26f32fd896b0a7b740129161bfb008b Mon Sep 17 00:00:00 2001 From: "Peter S. Mazinger" Date: Fri, 16 Dec 2005 01:05:56 +0000 Subject: Convert some users and get rid of __rpc_thread_createerr jump reloc, this was indeed a badly chosen name --- libc/inet/rpc/ruserpass.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'libc/inet/rpc/ruserpass.c') diff --git a/libc/inet/rpc/ruserpass.c b/libc/inet/rpc/ruserpass.c index 43291808d..728ea5bb7 100644 --- a/libc/inet/rpc/ruserpass.c +++ b/libc/inet/rpc/ruserpass.c @@ -50,6 +50,8 @@ #include #include +extern int __getc_unlocked (FILE *__stream) attribute_hidden; + #define _(X) (X) /* #include "ftp_var.h" */ @@ -219,7 +221,7 @@ next: (void) fclose(cfile); return (0); } - while ((c=getc_unlocked(cfile)) != EOF && c == ' ' + while ((c=__getc_unlocked(cfile)) != EOF && c == ' ' || c == '\t'); if (c == EOF || c == '\n') { __printf("Missing macdef name argument.\n"); @@ -231,7 +233,7 @@ next: } tmp = macros[macnum].mac_name; *tmp++ = c; - for (i=0; i < 8 && (c=getc_unlocked(cfile)) != EOF && + for (i=0; i < 8 && (c=__getc_unlocked(cfile)) != EOF && !isspace(c); ++i) { *tmp++ = c; } @@ -241,7 +243,7 @@ next: } *tmp = '\0'; if (c != '\n') { - while ((c=getc_unlocked(cfile)) != EOF + while ((c=__getc_unlocked(cfile)) != EOF && c != '\n'); } if (c == EOF) { @@ -256,7 +258,7 @@ next: } tmp = macros[macnum].mac_start; while (tmp != macbuf + 4096) { - if ((c=getc_unlocked(cfile)) == EOF) { + if ((c=__getc_unlocked(cfile)) == EOF) { __printf("Macro definition missing null line terminator.\n"); goto bad; } @@ -300,24 +302,24 @@ token() if (feof_unlocked(cfile) || ferror_unlocked(cfile)) return (0); - while ((c = getc_unlocked(cfile)) != EOF && + while ((c = __getc_unlocked(cfile)) != EOF && (c == '\n' || c == '\t' || c == ' ' || c == ',')) continue; if (c == EOF) return (0); cp = tokval; if (c == '"') { - while ((c = getc_unlocked(cfile)) != EOF && c != '"') { + while ((c = __getc_unlocked(cfile)) != EOF && c != '"') { if (c == '\\') - c = getc_unlocked(cfile); + c = __getc_unlocked(cfile); *cp++ = c; } } else { *cp++ = c; - while ((c = getc_unlocked(cfile)) != EOF + while ((c = __getc_unlocked(cfile)) != EOF && c != '\n' && c != '\t' && c != ' ' && c != ',') { if (c == '\\') - c = getc_unlocked(cfile); + c = __getc_unlocked(cfile); *cp++ = c; } } -- cgit v1.2.3