summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authormycroft <mycroft>2000-11-30 05:16:16 +0000
committermycroft <mycroft>2000-11-30 05:16:16 +0000
commita0d71f05a1d98871c118ac22480c6332fa9086ac (patch)
tree65da0c7f6281d21c24f212f3afc0d47fe6182521 /misc
parent95814528764fa3e4da6a1f40a44760beb5af8d42 (diff)
downloadpkgsrc-a0d71f05a1d98871c118ac22480c6332fa9086ac.tar.gz
Fix unsigned char problem that caused an infinite loop.
Diffstat (limited to 'misc')
-rw-r--r--misc/gnome-utils/patches/patch-af39
1 files changed, 39 insertions, 0 deletions
diff --git a/misc/gnome-utils/patches/patch-af b/misc/gnome-utils/patches/patch-af
new file mode 100644
index 00000000000..a4367b6922e
--- /dev/null
+++ b/misc/gnome-utils/patches/patch-af
@@ -0,0 +1,39 @@
+$NetBSD: patch-af,v 1.1 2000/11/30 05:16:16 mycroft Exp $
+
+--- logview/logrtns.c.orig Thu Apr 27 03:32:02 2000
++++ logview/logrtns.c Thu Nov 30 05:14:16 2000
+@@ -294,8 +294,8 @@
+ {
+ LogLine *line;
+ FILE *fp;
+- char *c, ch, buffer[R_BUF_SIZE + 1];
+- int ln;
++ char *c, buffer[R_BUF_SIZE + 1];
++ int ch, ln;
+ long int old_pos;
+
+ fp = lg->fp;
+@@ -308,9 +308,10 @@
+ pg->ll = LINES_P_PAGE - 1;
+
+ /* Tell if we are reading the last page */
+- if (fgetc (fp) == EOF)
++ ch = fgetc (fp);
++ ungetc (ch, fp);
++ if (ch == EOF)
+ pg->islastpage = TRUE;
+- ungetc (ch,fp);
+
+ while (ln >= pg->fl)
+ {
+@@ -364,8 +365,8 @@
+ {
+ FILE *fp;
+ LogLine *line;
+- char *c, ch, buffer[R_BUF_SIZE + 1];
+- int ln, len;
++ char *c, buffer[R_BUF_SIZE + 1];
++ int ch, ln, len;
+
+ fp = lg->fp;
+ ln = 0;