1
0
forked from 0ad/0ad

Detect allocation failure

This was SVN commit r10520.
This commit is contained in:
Ykkrosh 2011-11-12 23:57:33 +00:00
parent 7fcc76b621
commit f865401136

View File

@ -109,6 +109,7 @@ static bool IsMaxCpusSufficient()
{
const size_t setSize = CPU_ALLOC_SIZE(maxCpus);
cpu_set_t* set = CPU_ALLOC(maxCpus);
ENSURE(set);
const int ret = sched_getaffinity(0, setSize, set);
CPU_FREE(set);
if(ret == 0)