mirror of
https://github.com/clearlinux/uwsgi.git
synced 2026-09-06 21:51:30 +00:00
Use PL_sv_yes & PL_sv_no instead of newSViv(1) & newSViv(0) for bools
as they're interpreter globals that don't need to be created everytime.
Added a test and refactored the tests that were added with a1e30157,
all .t files in t/perl are now ran under all major perl versions with
and without threading when t/perl/run is invoked.
On my box, psgi_plugin.o went from 62,296 bytes to 62,208 bytes. Not a
huge saving I'll grant you, but every little helps :-)
11 lines
182 B
Perl
11 lines
182 B
Perl
use strict;
|
|
use warnings;
|
|
|
|
sub {
|
|
my $env = shift;
|
|
|
|
my $body = join "\n", map "$_\n$env->{$_}", sort keys %$env;
|
|
|
|
[ 200, [ 'Content-type' => 'text/plain' ], [$body] ];
|
|
};
|