Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(149)

Side by Side Diff: src/pkg/http/cgi/testdata/test.cgi

Issue 4291069: code review 4291069: http: modified perl cgi test to remove newline from env...
Patch Set: diff -r fad73d342108 https://go.googlecode.com/hg/ Created 13 years, 11 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/perl 1 #!/usr/bin/perl
2 # Copyright 2011 The Go Authors. All rights reserved. 2 # Copyright 2011 The Go Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style 3 # Use of this source code is governed by a BSD-style
4 # license that can be found in the LICENSE file. 4 # license that can be found in the LICENSE file.
5 # 5 #
6 # Test script run as a child process under cgi_test.go 6 # Test script run as a child process under cgi_test.go
7 7
8 use strict; 8 use strict;
9 use CGI; 9 use CGI;
10 10
(...skipping 12 matching lines...) Expand all
23 $p->("X-Test-Header: X-Test-Value"); 23 $p->("X-Test-Header: X-Test-Value");
24 $p->(""); 24 $p->("");
25 25
26 print "test=Hello CGI\n"; 26 print "test=Hello CGI\n";
27 27
28 foreach my $k (sort keys %$params) { 28 foreach my $k (sort keys %$params) {
29 print "param-$k=$params->{$k}\n"; 29 print "param-$k=$params->{$k}\n";
30 } 30 }
31 31
32 foreach my $k (sort keys %ENV) { 32 foreach my $k (sort keys %ENV) {
33 print "env-$k=$ENV{$k}\n"; 33 print "env-$k=".do { (my $new_env = $ENV{$k}) =~ s/[\n\r]//g; $new_env } . "\n ";
bradfitz 2011/03/25 14:56:35 Thanks for the fix! I'd prefer if we didn't play
34 } 34 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b