From 9ab701643a1ed5b165c1fa0d9e5c891d7caaf78f Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Fri, 8 Mar 2002 03:28:38 +0000 Subject: [w3m-dev 03088] gopher broken (Re: Bug#137287: w3m: segfault on gopher://xxxx.xxx URI) * file.c (form_max): initial value should be -1 * file.c (loadGopherDir): From: Fumitoshi UKAI --- file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'file.c') diff --git a/file.c b/file.c index 015d18e..46cca25 100644 --- a/file.c +++ b/file.c @@ -1,4 +1,4 @@ -/* $Id: file.c,v 1.74 2002/03/05 16:58:09 ukai Exp $ */ +/* $Id: file.c,v 1.75 2002/03/08 03:28:38 ukai Exp $ */ #include "fm.h" #include #include "myctype.h" @@ -115,7 +115,7 @@ static struct link_stack *link_stack = NULL; #define INITIAL_FORM_SIZE 10 static FormList **forms; static int *form_stack; -static int form_max = 0; +static int form_max = -1; static int forms_size = 0; #define cur_form_id ((form_sp >= 0)? form_stack[form_sp] : -1) static int form_sp = 0; @@ -6287,6 +6287,7 @@ loadGopherDir(URLFile *uf, Buffer *newBuf) Strcat_charp(lbuf, "\">"); Strcat_charp(lbuf, p); Strcat_charp(lbuf, name->ptr + 1); + Strcat_charp(lbuf, ""); pushTextLine(tl, newTextLine(lbuf, visible_length(lbuf->ptr))); } #ifdef JP_CHARSET -- cgit v1.2.3