From 955cba9cff81e9aa29c41793fe04aa14bc0fdeb2 Mon Sep 17 00:00:00 2001 From: Vitaly Driedfruit Date: Thu, 17 May 2012 01:31:31 +0400 Subject: [PATCH] Minor changes to CGI interface. --- public_gopher/script.pl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/public_gopher/script.pl b/public_gopher/script.pl index 89b41b9..70114f6 100755 --- a/public_gopher/script.pl +++ b/public_gopher/script.pl @@ -1,14 +1,14 @@ #!/usr/bin/perl -if ($ENV{"SEARCH"}) { +if ($ENV{"QUERY_STRING"}) { # Request - $cookie = $ENV{"SEARCH"}; - $data_size = $ENV{"DATA_SIZE"} || 1024; + $cookie = $ENV{"QUERY_STRING"}; + $data_size = $ENV{"CONTENT_SIZE"} || 1024; $data_read = 0; $data_read = read(STDIN, $data, $data_size); - $target = 's'.$ENV{"SELECTOR"}."\t"."gadl"."\t\t\r\n"; + $target = 's'.$ENV{"GOPHER_SELECTOR"}."\t"."gadl"."\t\t\r\n"; $buffer = ""; @lines = split /\n/, $data; @@ -32,7 +32,7 @@ if ($ENV{"SEARCH"}) { # Form $cookie = rand(); - $target = 's'.$ENV{"SELECTOR"}."\t".$cookie."\t\t\r\n"; + $target = 's'.$ENV{"GOPHER_SELECTOR"}."\t".$cookie."\t\t\r\n"; $buffer = ""; $buffer .= $target; -- 2.11.4.GIT