286270 vgpreload is not friendly to 64->32 bit execs, gives ld.so warnings
286374 Running cachegrind with --branch-sim=yes on 64-bit PowerPC program fails
287858 VG_(strerror): unknown error
-
+289699 vgdb connection in relay mode erroneously closed due to buffer overrun
Release 3.7.0 (5 November 2011)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
static
Bool read_from_gdb_write_to_pid(int to_pid)
{
- char buf[PBUFSIZ];
+ char buf[PBUFSIZ+1]; // +1 for trailing \0
int nrread;
nrread = read_buf(from_gdb, buf, "from gdb on stdin");
static
Bool read_from_pid_write_to_gdb(int from_pid)
{
- char buf[PBUFSIZ];
+ char buf[PBUFSIZ+1]; // +1 for trailing \0
int nrread;
nrread = read_buf(from_pid, buf, "from pid");
static int
readchar (int fd)
{
- static unsigned char buf[PBUFSIZ];
+ static unsigned char buf[PBUFSIZ+1]; // +1 for trailing \0
static int bufcnt = 0;
static unsigned char *bufp;
if (bufcnt-- > 0)
return *bufp++;
- bufcnt = read (fd, buf, sizeof (buf));
+ bufcnt = read_buf (fd, buf, "static buf readchar");
if (bufcnt <= 0) {
if (bufcnt == 0) {
if (!read_from_gdb_write_to_pid(to_pid))
shutting_down = True;
break;
- case FROM_PID:
- if (!read_from_pid_write_to_gdb(from_pid))
- shutting_down = True;
- break;
+ case FROM_PID:
+ if (!read_from_pid_write_to_gdb(from_pid))
+ shutting_down = True;
+ break;
default: XERROR(0, "unexpected POLLIN on %s\n",
ppConnectionKind(ck));
}
unsigned char hex[3];
unsigned char cksum;
unsigned char *hexcommand;
- unsigned char buf[PBUFSIZ];
+ unsigned char buf[PBUFSIZ+1]; // +1 for trailing \0
int buflen;
int nc;