diff --git a/src/sigar.c b/src/sigar.c index 285e6493..c0e9cb49 100644 --- a/src/sigar.c +++ b/src/sigar.c @@ -39,8 +39,8 @@ SIGAR_DECLARE(int) sigar_open(sigar_t **sigar) int status = sigar_os_open(sigar); if (status == SIGAR_OK) { - /* XXX tmp hack */ - (*sigar)->cpu_list_cores = getenv("SIGAR_CPU_CORES") ? 1 : 0; + /* use env to revert to old behavior */ + (*sigar)->cpu_list_cores = getenv("SIGAR_CPU_LIST_SOCKETS") ? 0 : 1; (*sigar)->pid = 0; (*sigar)->ifconf_buf = NULL; (*sigar)->ifconf_len = 0;