diff -u ../hugs98-Dec2001/src/input.c src/input.c
--- ../hugs98-Dec2001/src/input.c	2002-07-15 03:21:03.000000000 +1000
+++ src/input.c	2002-07-29 17:47:18.000000000 +1000
@@ -309,11 +309,22 @@
     return isIn(c,LARGE);
 }
 
+/* BUGFIX: Menaka Lashitha Bandara <lashi@optusnet.com.au>
+ * 	   <lashi@lashitha.org> -- doesn't work at the moment, but preffered.
+ * (char) *lineBuffer causes a comparison lineBuffer [lineLength] == EOF to
+ * always be false, thereby not being able to Parse files on some machines. */
+
+#if EOF < 0
+#define LINE_BUFFER_SIZE_TYPE	signed char
+#else
+#define LINE_BUFFER_SIZE_TYPE 	char
+#endif
+
 #if HAVE_GETDELIM_H
-static char *lineBuffer = NULL;   /* getline() does the initial allocation */
+static LINE_BUFFER_SIZE_TYPE *lineBuffer = NULL;   /* getline() does the initial allocation */
 #else
 #define LINEBUFFER_SIZE 1000
-static char lineBuffer[LINEBUFFER_SIZE];
+static LINE_BUFFER_SIZE_TYPE lineBuffer[LINEBUFFER_SIZE];
 #endif
 static int lineLength = 0;
 static int inCodeBlock = FALSE; /* Inside \begin{code}..\end{code} */
