[ 2161732 ] valgrind check error

git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@1375 b68d4a1b-bc3d-0410-92ed-d4ac073336b7
master
Jie Zhang 16 years ago
parent 113d9b9454
commit 5a19b361e4

@ -1,3 +1,8 @@
2008-10-13 Jie Zhang <jie.zhang@analog.com>
* src/tap/cable/ft2232.c (ft2232_transfer_schedule): Don't
access memory out of bounds.
2008-10-11 Arnim Laeuger <arniml@users.sourceforge.net>
* src/bus/ejtag.c (ejtag_bus_init): added remaining return values

@ -1052,7 +1052,7 @@ ft2232_transfer_schedule( cable_t *cable, int len, char *in, char *out )
{
int bit_idx;
unsigned char b = 0;
for (bit_idx = 1; bit_idx <= 1 << bitwise_len; bit_idx <<= 1)
for (bit_idx = 1; bit_idx < 1 << bitwise_len; bit_idx <<= 1)
{
if (in[in_offset++])
b |= bit_idx;

Loading…
Cancel
Save