mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* test/ruby/memory_status.rb (Memory): syntax error.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34857 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1673881f58
commit
74b70ad879
2 changed files with 5 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Wed Feb 29 15:38:50 2012 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||||
|
|
||||||
|
* test/ruby/memory_status.rb (Memory): syntax error.
|
||||||
|
|
||||||
Wed Feb 29 13:06:42 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Wed Feb 29 13:06:42 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* test/ruby/memory_status.rb: use /proc/self/status if it is in
|
* test/ruby/memory_status.rb: use /proc/self/status if it is in
|
||||||
|
|
|
@ -3,7 +3,7 @@ module Memory
|
||||||
vals = []
|
vals = []
|
||||||
|
|
||||||
case
|
case
|
||||||
when File.exist?(procfile = "/proc/self/status") and (pat = /^Vm(\w+):\s+(\d+)/) =~ File.binread(procfile)
|
when File.exist?(procfile = "/proc/self/status") && (pat = /^Vm(\w+):\s+(\d+)/) =~ File.binread(procfile)
|
||||||
PROC_FILE = procfile
|
PROC_FILE = procfile
|
||||||
VM_PAT = pat
|
VM_PAT = pat
|
||||||
def self.read_status
|
def self.read_status
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue