aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorMark Wielaard <mark@klomp.org>2024-01-21 21:51:26 +0100
committerMark Wielaard <mark@klomp.org>2024-01-22 18:16:42 +0100
commit5bc519bf0c8d34df4fe5e37511a7ddee518684d1 (patch)
treefd0b4d15fac79ffc5df84e91c320098905d54e21 /binutils
parent46bdb641642d20307521f5db2e1f1c7dcc49d5a7 (diff)
downloadbinutils-5bc519bf0c8d34df4fe5e37511a7ddee518684d1.zip
binutils-5bc519bf0c8d34df4fe5e37511a7ddee518684d1.tar.gz
binutils-5bc519bf0c8d34df4fe5e37511a7ddee518684d1.tar.bz2
opcodes: tic4x_disassemble swap xcalloc arguments
GCC 14 will detect when the size and count arguments of calloc are swapped. binutils-gdb/opcodes/tic4x-dis.c: In function ‘tic4x_disassemble’: binutils-gdb/opcodes/tic4x-dis.c:710:32: error: ‘xcalloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Werror=calloc-transposed-args] 710 | optab = xcalloc (sizeof (tic4x_inst_t *), (1 << TIC4X_HASH_SIZE)); | ^~~~~~~~~~~~ binutils-gdb/opcodes/tic4x-dis.c:710:32: note: earlier argument should specify number of elements, later size of each element binutils-gdb/opcodes/tic4x-dis.c:712:40: error: ‘xcalloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Werror=calloc-transposed-args] 712 | optab_special = xcalloc (sizeof (tic4x_inst_t *), TIC4X_SPESOP_SIZE); | ^~~~~~~~~~~~ binutils-gdb/opcodes/tic4x-dis.c:712:40: note: earlier argument should specify number of elements, later size of each element opcodes/ChangeLog: * /tic4x-dis.c (tic4x_disassemble): Swap size and count xcalloc arguments.
Diffstat (limited to 'binutils')
0 files changed, 0 insertions, 0 deletions