1 # Copyright (C) 2015 all contributors <meta@public-inbox.org>
2 # License: AGPLv3 or later (https://www.gnu.org/licenses/agpl-3.0.txt)
9 my $io = IO::File->new_tmpfile;
10 my $dup = dup($io->fileno);
11 my $response = sub { $headers = \@_, $io };
14 $io->fdopen($dup, 'r+');
16 $io->read(my $str, ($io->stat)[7]);