Don't cast return value of [cm]alloc

Change-Id: I0028a5b6757b1ba00031893d9a2a1725f915a0d5
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/2069
Tested-by: jenkins
Reviewed-by: Jörg Wunsch <openocd@uriah.heep.sax.de>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
This commit is contained in:
Andreas Fritiofson
2014-03-28 20:00:21 +01:00
committed by Paul Fertser
parent 1171f07836
commit e6907e6d7e
14 changed files with 76 additions and 76 deletions

View File

@@ -591,7 +591,7 @@ int arm11_run_instr_data_to_core_noack_inner_default(struct jtag_tap *tap,
unsigned readiesNum = count;
unsigned bytes = sizeof(*Readies)*readiesNum;
Readies = (uint8_t *) malloc(bytes);
Readies = malloc(bytes);
if (Readies == NULL) {
LOG_ERROR("Out of memory allocating %u bytes", bytes);
return ERROR_FAIL;