Fix order of calloc arguments.

(Patch by Dawid Gajownik)
This commit is contained in:
Hisham Muhammad
2014-01-16 18:51:16 -02:00
parent c1e0f6e17c
commit 76a715ee8c
9 changed files with 13 additions and 13 deletions

View File

@ -152,7 +152,7 @@ static void AllCPUsMeter_getRange(Meter* this, int* start, int* count) {
static void AllCPUsMeter_init(Meter* this) {
int cpus = this->pl->cpuCount;
if (!this->drawData)
this->drawData = calloc(sizeof(Meter*), cpus);
this->drawData = calloc(cpus, sizeof(Meter*));
Meter** meters = (Meter**) this->drawData;
int start, count;
AllCPUsMeter_getRange(this, &start, &count);