riscv-openocd/src/jtag
Paul Fertser 20fcd0729e jtag/tcl: fix incorrect memcpy in jim_newtap_expected_id
Found by clang static checker.

On the very first call of jim_newtap_expected_id() pTap->expected_ids
and expected_len are null, and there's nothing to copy. This patch
changes this cryptic code to use realloc() instead.

Change-Id: Ic0b5140d08257a906f15b55a2ae64db7bc06d5f1
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/2562
Reviewed-by: Stian Skjelstad <stian@nixia.no>
Tested-by: jenkins
2015-04-14 12:09:48 +01:00
..
aice libusb: introduce jtag_libusb_choose_interface() and use it for JLink 2014-10-06 18:40:39 +00:00
drivers jtag/drivers/ftdi.c: removed memory leak 2015-03-25 21:52:09 +00:00
hla armv7m_trace, stlink: provide APIs to capture trace with an adapter 2015-03-25 20:46:59 +00:00
minidriver Retire jtag_add_dr_out 2014-01-20 13:28:26 +00:00
minidummy Retire jtag_add_dr_out 2014-01-20 13:28:26 +00:00
zy1000 Retire jtag_add_dr_out 2014-01-20 13:28:26 +00:00
Makefile.am aice: add Andes AICE support 2013-06-05 19:27:23 +00:00
adapter.c transport: Constify the transports vector 2014-06-28 09:33:31 +00:00
commands.c jtag: fix support for really long scans 2013-11-06 13:08:38 +00:00
commands.h update files to correct FSF address 2013-06-05 19:52:42 +00:00
core.c jtag/core: honour SRST timings in SWD mode 2015-04-14 11:41:54 +01:00
driver.h update files to correct FSF address 2013-06-05 19:52:42 +00:00
interface.c update files to correct FSF address 2013-06-05 19:52:42 +00:00
interface.h armv7m_trace, stlink: provide APIs to capture trace with an adapter 2015-03-25 20:46:59 +00:00
interfaces.c jtag/drivers: add USB-Blaster II 2014-01-20 13:28:02 +00:00
interfaces.h update files to correct FSF address 2013-06-05 19:52:42 +00:00
jtag.h Retire jtag_add_dr_out 2014-01-20 13:28:26 +00:00
minidriver.h Retire jtag_add_dr_out 2014-01-20 13:28:26 +00:00
startup.tcl startup: Fixed measure_clk to return kHz instead of MHz. 2015-04-14 11:50:03 +01:00
swd.h drivers/cmsis-dap: port to common SWD framework 2015-03-25 21:31:09 +00:00
tcl.c jtag/tcl: fix incorrect memcpy in jim_newtap_expected_id 2015-04-14 12:09:48 +01:00
tcl.h update files to correct FSF address 2013-06-05 19:52:42 +00:00