mirror of
https://github.com/neovim/neovim.git
synced 2026-05-04 21:15:09 +00:00
* Add const. * Fix conditions (move && from end to start of line). * Use int32_t instead of long. * Use //-style comments.
14 lines
384 B
C
14 lines
384 B
C
// os.c -- OS-level calls to query hardware, etc.
|
|
|
|
#include <uv.h>
|
|
|
|
#include "os/os.h"
|
|
|
|
// Return total amount of memory available in Kbyte.
|
|
// Doesn't change when memory has been allocated.
|
|
long_u os_total_mem(int special) {
|
|
// We need to return memory in *Kbytes* but uv_get_total_memory() returns the
|
|
// number of bytes of total memory.
|
|
return uv_get_total_memory() >> 10;
|
|
}
|