Prevent collision with getline(3)
This commit is contained in:
parent
ca7f419d50
commit
00c788d997
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=415027
20
lang/hope/files/patch-src_source.c
Normal file
20
lang/hope/files/patch-src_source.c
Normal file
@ -0,0 +1,20 @@
|
||||
--- src/source.c.orig 1999-04-09 23:40:26 UTC
|
||||
+++ src/source.c
|
||||
@@ -250,7 +250,7 @@ static const char *const errname[] = {
|
||||
abort();
|
||||
if (errtype >= FATALERR) {
|
||||
if (gen_listing) /* copy the rest to the listing */
|
||||
- while (getline())
|
||||
+ while (get_line())
|
||||
;
|
||||
(void)exit(1);
|
||||
}
|
||||
@@ -287,7 +287,7 @@ interactive(void)
|
||||
* otherwise it ends in a newline (whitespace) and then a null.
|
||||
*/
|
||||
global Bool
|
||||
-getline(void)
|
||||
+get_line(void)
|
||||
{
|
||||
if (atend && cur_source >= source) {
|
||||
if (cur_source > source)
|
11
lang/hope/files/patch-src_source.h
Normal file
11
lang/hope/files/patch-src_source.h
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/source.h.orig 1997-06-09 08:02:53 UTC
|
||||
+++ src/source.h
|
||||
@@ -8,7 +8,7 @@ extern const Byte *inptr;
|
||||
extern void init_source(FILE *src, Bool gen_listing);
|
||||
extern void enterfile(FILE *f);
|
||||
extern Bool interactive(void);
|
||||
-extern Bool getline(void);
|
||||
+extern Bool get_line(void);
|
||||
|
||||
#ifdef RE_EDIT
|
||||
extern void set_script(const char *filename);
|
11
lang/hope/files/patch-src_yylex.c
Normal file
11
lang/hope/files/patch-src_yylex.c
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/yylex.c.orig 1999-04-09 12:21:08 UTC
|
||||
+++ src/yylex.c
|
||||
@@ -157,7 +157,7 @@ yylex(void)
|
||||
inptr = start;
|
||||
return ';';
|
||||
}
|
||||
- if (! getline())
|
||||
+ if (! get_line())
|
||||
return EOF;
|
||||
} else if (IsDigit(c)) {
|
||||
/*
|
Loading…
Reference in New Issue
Block a user