perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tors...@apache.org
Subject svn commit: r1069513 - /perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm
Date Thu, 10 Feb 2011 18:34:43 GMT
Author: torsten
Date: Thu Feb 10 18:34:43 2011
New Revision: 1069513

URL: http://svn.apache.org/viewvc?rev=1069513&view=rev
Log:
"unshared" now means on Linux private_clean+private_dirty instead of size-shared

Modified:
    perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm

Modified: perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm
URL: http://svn.apache.org/viewvc/perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm?rev=1069513&r1=1069512&r2=1069513&view=diff
==============================================================================
--- perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm (original)
+++ perl/Apache-SizeLimit/trunk/lib/Apache/SizeLimit/Core.pm Thu Feb 10 18:34:43 2011
@@ -117,9 +117,9 @@ sub _limits_are_exceeded {
 sub _check_size {
     my $class = shift;
 
-    my ($size, $share) = $class->_platform_check_size();
+    my ($size, $share, $unshared) = $class->_platform_check_size();
 
-    return ($size, $share, $size - $share);
+    return ($size, $share, defined $unshared ? $unshared : $size - $share);
 }
 
 sub _load {
@@ -176,7 +176,9 @@ sub _linux_smaps_size_check {
     return $class->_linux_size_check() unless $USE_SMAPS;
 
     my $s = Linux::Smaps->new($$)->all;
-    return ($s->size, $s->shared_clean + $s->shared_dirty);
+    return ($s->size,
+	    $s->shared_clean + $s->shared_dirty,
+	    $s->private_clean + $s->private_dirty);
 }
 
 sub _linux_size_check {



Mime
View raw message