$NetBSD: patch-ac,v 1.5 2004/01/27 01:24:52 recht Exp $

--- src/proxy.c.orig	2004-01-10 05:04:56.000000000 +0100
+++ src/proxy.c
@@ -974,7 +974,7 @@ http_canread(gpointer data, gint source,
 
 	gaim_input_remove(phb->inpa);
 
-	while ((nlc != 2) && (read(source, &inputline[pos++], 1) == 1)) {
+	while ((pos < sizeof(inputline)-1) && (nlc != 2) && (read(source, &inputline[pos++], 1) == 1)) {
 		if (inputline[pos - 1] == '\n')
 			nlc++;
 		else if (inputline[pos - 1] != '\r')
