Method: LinuxStat::Sysinfo.freeswap
- Defined in:
- ext/sysinfo/sysinfo.c
.freeswap ⇒ Object
62 63 64 65 66 67 68 69 |
# File 'ext/sysinfo/sysinfo.c', line 62 VALUE freeswap(VALUE obj) { char status = sysinfo(&info) ; if (status < 0) return Qnil ; VALUE _rb_v = ULL2NUM((unsigned long long) info.freeswap) ; VALUE _rb_mem_unit = ULL2NUM((unsigned long long) info.mem_unit) ; return rb_funcallv_public(_rb_v, rb_intern("*"), 1, &_rb_mem_unit) ; } |