diff options
author | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-01-02 06:41:47 +0000 |
---|---|---|
committer | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-01-02 06:41:47 +0000 |
commit | 91715ee53b370e958a7c1a2e1036aa71eed66fc1 (patch) | |
tree | 15fc64af27f54199b3ec086d76da7ee8b72923d0 /ext/-test- | |
parent | 1836af769cc8fc78a5d017b5a51aebfa6794f7b5 (diff) | |
download | ruby-91715ee53b370e958a7c1a2e1036aa71eed66fc1.tar.gz |
long long is a C99ism
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/-test-')
-rw-r--r-- | ext/-test-/memory_status/memory_status.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/-test-/memory_status/memory_status.c b/ext/-test-/memory_status/memory_status.c index 23c4806472..5775fa56f3 100644 --- a/ext/-test-/memory_status/memory_status.c +++ b/ext/-test-/memory_status/memory_status.c @@ -32,6 +32,10 @@ read_status(VALUE self) error = task_info(mach_task_self(), flavor, (task_info_t)&taskinfo, &out_count); if (error != KERN_SUCCESS) return Qnil; +#ifndef ULL2NUM +/* "long long" does not exist here, use size_t instead. */ +#define ULL2NUM SIZET2NUM +#endif size = ULL2NUM(taskinfo.virtual_size); rss = ULL2NUM(taskinfo.resident_size); rb_struct_aset(self, INT2FIX(1), rss); |