summaryrefslogtreecommitdiff
path: root/news/cg
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2016-05-11 21:51:01 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2016-05-11 21:51:01 +0000
commit25269d65dbf89ed02076d5a47c0ed8e56e46a944 (patch)
tree6b25aa33ee8f4de52961e4bb86059d448c9f3de4 /news/cg
parentPrevent collision with getline(3) (diff)
Prevent collision with get_line
Notes
Notes: svn path=/head/; revision=415037
Diffstat (limited to 'news/cg')
-rw-r--r--news/cg/files/patch-util.c20
-rw-r--r--news/cg/files/patch-util.h11
2 files changed, 31 insertions, 0 deletions
diff --git a/news/cg/files/patch-util.c b/news/cg/files/patch-util.c
new file mode 100644
index 000000000000..05e2c8e4fcfb
--- /dev/null
+++ b/news/cg/files/patch-util.c
@@ -0,0 +1,20 @@
+--- util.c.orig 2002-05-13 16:27:29 UTC
++++ util.c
+@@ -180,7 +180,7 @@ rename_uniq(const char *from, char **to)
+
+
+ char *
+-getline(FILE *f)
++get_line(FILE *f)
+ {
+ static char *b;
+ static int bsize;
+@@ -234,7 +234,7 @@ getline(FILE *f)
+ void
+ skip_rest(FILE *f)
+ {
+- while (getline(f) != NULL)
++ while (get_line(f) != NULL)
+ ;
+ }
+
diff --git a/news/cg/files/patch-util.h b/news/cg/files/patch-util.h
new file mode 100644
index 000000000000..2228d5475e7f
--- /dev/null
+++ b/news/cg/files/patch-util.h
@@ -0,0 +1,11 @@
+--- util.h.orig 2002-04-24 15:45:24 UTC
++++ util.h
+@@ -57,7 +57,7 @@ void copy_stream(stream *in, out_state *
+ void debug(out_state *out, char *fmt, ...);
+ char *expand(char *path);
+ FILE *fopen_uniq(char **s);
+-char *getline(FILE *f);
++char *get_line(FILE *f);
+ void output_header(out_state *out, symbol name, struct header *h);
+ void prdebug(int level, char *fmt, ...);
+ void prdebug_init(int do_file, int do_stdout);