diff options
| author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-02-09 07:11:23 +0000 |
|---|---|---|
| committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-02-09 07:11:23 +0000 |
| commit | 71837f629e3fb0923a16897d1a499515c585dfdf (patch) | |
| tree | 6ef6c9599d0af3c0d429c0e44770be5ad399eae4 | |
| parent | b2ba3242ea433a807264563c0f2d84652c537637 (diff) | |
* test/ruby/memory_status.rb (Memory::Win32): 64bit support.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34508 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 4 | ||||
| -rw-r--r-- | test/ruby/memory_status.rb | 6 |
2 files changed, 9 insertions, 1 deletions
@@ -1,3 +1,7 @@ +Thu Feb 9 16:10:34 2012 NAKAMURA Usaku <usa@ruby-lang.org> + + * test/ruby/memory_status.rb (Memory::Win32): 64bit support. + Thu Feb 9 16:08:55 2012 NAKAMURA Usaku <usa@ruby-lang.org> * ext/dl/lib/value.rb (DL::ValueUtil.{unsigned_value,signed_value}): diff --git a/test/ruby/memory_status.rb b/test/ruby/memory_status.rb index d0596ccd5e..f504c0a736 100644 --- a/test/ruby/memory_status.rb +++ b/test/ruby/memory_status.rb @@ -22,7 +22,11 @@ module Memory extend DL::Importer dlload "kernel32.dll", "psapi.dll" include DL::Win32Types - typealias "SIZE_T", "DWORD" + if [nil].pack('p').bytesize == 8 + typealias "SIZE_T", "DWORD64" + else + typealias "SIZE_T", "DWORD32" + end PROCESS_MEMORY_COUNTERS = struct [ "DWORD cb", |
