From 500effe79ebbb9b130d2ad5a86c92c2f960f2456 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= Date: Fri, 25 Mar 2011 09:33:45 -0700 Subject: [PATCH] http: modified perl cgi test to remove newline from env variables Fixes #1639 R=golang-dev, bradfitzgo CC=golang-dev https://golang.org/cl/4291069 --- src/pkg/http/cgi/testdata/test.cgi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pkg/http/cgi/testdata/test.cgi b/src/pkg/http/cgi/testdata/test.cgi index 8c10dde32b7..253589eed96 100755 --- a/src/pkg/http/cgi/testdata/test.cgi +++ b/src/pkg/http/cgi/testdata/test.cgi @@ -30,5 +30,7 @@ foreach my $k (sort keys %$params) { } foreach my $k (sort keys %ENV) { - print "env-$k=$ENV{$k}\n"; + my $clean_env = $ENV{$k}; + $clean_env =~ s/[\n\r]//g; + print "env-$k=$clean_env\n"; }