Skip to content

Instantly share code, notes, and snippets.

@hanabokuro
Created May 16, 2012 11:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hanabokuro/2709534 to your computer and use it in GitHub Desktop.
Save hanabokuro/2709534 to your computer and use it in GitHub Desktop.
pnotes leak (perl5.8 + mod_perl-2.0.4)
#!/usr/bin/perl
use strict;
use warnings;
use B;
use Apache2::RequestUtil;
print <<"END;";
Content-type: text/plain
END;
for(1..10){
my $notes_ref = Apache2::RequestUtil->request->pnotes();
my $count = B::SV::REFCNT(B::svref_2object($notes_ref));
print "count[$count]\n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment