From 4d529919d444baa6c9b752ca7263edbf524f5de0 Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Tue, 25 Feb 2003 16:01:38 +0000 Subject: [w3m-dev 03781] Debian Bug report logs - #181897: w3m submits query urls with "extra" * main.c (_followForm): remove tailling '?' From: Hironori SAKAMOTO --- main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'main.c') diff --git a/main.c b/main.c index 5aec367..9a7582a 100644 --- a/main.c +++ b/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.211 2003/02/18 15:43:25 ukai Exp $ */ +/* $Id: main.c,v 1.212 2003/02/25 16:01:41 ukai Exp $ */ #define MAINPROGRAM #include "fm.h" #include @@ -3295,6 +3295,8 @@ _followForm(int submit) } if (fi->parent->method == FORM_METHOD_GET) { + if ((p = strchr(tmp2->ptr, '?')) != NULL) + Strshrink(tmp2, (tmp2->ptr + tmp2->length) - p); Strcat_charp(tmp2, "?"); Strcat(tmp2, tmp); loadLink(tmp2->ptr, a->target, NULL, NULL); -- cgit v1.2.3