w3m

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/w3m.git/
Log | Files | Refs | README

commit a4f348827d0f590e57b9f082c716ace94a44bcd3
parent 1feddd22128ccd1d8d4b1180cdd7f81e93ffa4b1
Author: ukai <ukai>
Date:   Thu, 18 Jul 2002 13:12:07 +0000

[w3m-dev 03275] fix of multipart.cgi
* scripts/multipart/multipart.cgi.in: check REQUEST_METHOD first
				need $count for POST
From: Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>

Diffstat:
MChangeLog | 6++++++
Mscripts/multipart/multipart.cgi.in | 8++++----
2 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,9 @@ +2002-07-18 Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp> + + * [w3m-dev 03275] fix of multipart.cgi + * scripts/multipart/multipart.cgi.in: check REQUEST_METHOD first + need $count for POST + 2002-07-18 Fumitoshi UKAI <ukai@debian.or.jp> * w3mimgdisplay.c (main): '5' for w3mimgsize diff --git a/scripts/multipart/multipart.cgi.in b/scripts/multipart/multipart.cgi.in @@ -16,10 +16,10 @@ $MIME_TYPE = "$ENV{'HOME'}/.mime.types"; $SCRIPT_NAME = $ENV{'SCRIPT_NAME'} || $0; $CGI = "file://$SCRIPT_NAME"; -if (defined($ENV{'QUERY_STRING'})) { - $query = $ENV{'QUERY_STRING'}; -} elsif ($ENV{'REQUEST_METHOD'} eq 'POST') { +if ($ENV{'REQUEST_METHOD'} eq 'POST') { sysread(STDIN, $query, $ENV{'CONTENT_LENGTH'}); +} elsif (defined($ENV{'QUERY_STRING'})) { + $query = $ENV{'QUERY_STRING'}; } if (defined($query)) { for (split('&', $query)) { @@ -192,7 +192,7 @@ while(! $end) { } else { $name = "Content"; } - print "<form method=POST action=\"$qcgi\">\n"; + print "<form method=POST action=\"$qcgi?$count\">\n"; print "<input type=hidden name=file value=\"$qfile\">\n"; print "<input type=hidden name=boundary value=\"$qboundary\">\n"; print "<input type=hidden name=count value=\"$count\">\n";