Changes in uspace/lib/trackmod/protracker.c [d1582b50:56210a7] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/trackmod/protracker.c
rd1582b50 r56210a7 146 146 147 147 cells = module->channels * protracker_pattern_rows; 148 buf = calloc( sizeof(uint32_t), cells);148 buf = calloc(cells, sizeof(uint32_t)); 149 149 150 150 if (buf == NULL) { … … 156 156 module->pattern[i].rows = protracker_pattern_rows; 157 157 module->pattern[i].channels = module->channels; 158 module->pattern[i].data = calloc( sizeof(trackmod_cell_t), cells);158 module->pattern[i].data = calloc(cells, sizeof(trackmod_cell_t)); 159 159 if (module->pattern[i].data == NULL) { 160 160 rc = ENOMEM; … … 326 326 327 327 module->instrs = samples; 328 module->instr = calloc(s izeof(trackmod_instr_t), samples);328 module->instr = calloc(samples, sizeof(trackmod_instr_t)); 329 329 if (module->instr == NULL) { 330 330 printf("Out of memory.\n"); … … 334 334 335 335 module->patterns = patterns; 336 module->pattern = calloc( sizeof(trackmod_pattern_t), patterns);336 module->pattern = calloc(patterns, sizeof(trackmod_pattern_t)); 337 337 if (module->pattern == NULL) { 338 338 printf("Out of memory.\n"); … … 343 343 /* Order list */ 344 344 module->ord_list_len = order_list->order_list_len; 345 module->ord_list = calloc( sizeof(size_t), module->ord_list_len);345 module->ord_list = calloc(module->ord_list_len, sizeof(size_t)); 346 346 if (module->ord_list == NULL) { 347 347 printf("Out of memory.\n");
Note:
See TracChangeset
for help on using the changeset viewer.