Fix 64 bit problem in vvp/vpi_signal.c

This is based on a suggested fix from Martin. It fixes the crash
for two tests in the test suite. As a bonus it is more efficient.
This commit is contained in:
Cary R
2009-09-13 08:18:11 -07:00
committed by Stephen Williams
parent 6d5d06cae4
commit 43f41572cb
+1 -1
View File
@@ -138,8 +138,8 @@ static void format_vpiBinStrVal(vvp_fun_signal_vec*sig, int base, unsigned wid,
s_vpi_value*vp)
{
char *rbuf = need_result_buf(wid+1, RBUF_VAL);
long offset = wid - 1 + base;
long end = base + (signed)wid;
long offset = end - 1;
long ssize = (signed)sig->size();
for (long idx = base ; idx < end ; idx += 1) {