diff options
author | Michael Snyder <msnyder@vmware.com> | 2011-02-27 23:32:04 +0000 |
---|---|---|
committer | Michael Snyder <msnyder@vmware.com> | 2011-02-27 23:32:04 +0000 |
commit | 9130f83ec812cc215a1c1d22451c8b80005c7f4d (patch) | |
tree | a2aa4377e927e28d605ed4038bba7e26a724fec3 /gdb/gdbserver | |
parent | 9a7d3aa9ac20682634125afbcdd30a6f6cd2ea49 (diff) | |
download | gdb-9130f83ec812cc215a1c1d22451c8b80005c7f4d.zip gdb-9130f83ec812cc215a1c1d22451c8b80005c7f4d.tar.gz gdb-9130f83ec812cc215a1c1d22451c8b80005c7f4d.tar.bz2 |
2011-02-27 Michael Snyder <msnyder@vmware.com>
* hostio.c (require_data): Free malloc memory before returning
error.
Diffstat (limited to 'gdb/gdbserver')
-rw-r--r-- | gdb/gdbserver/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/gdbserver/hostio.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 1aaf401..62c612c 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2011-02-27 Michael Snyder <msnyder@vmware.com> + + * hostio.c (require_data): Free malloc memory before returning + error. + 2011-02-26 Michael Snyder <msnyder@vmware.com> * linux-low.c (list_threads): Call closedir for dirent. diff --git a/gdb/gdbserver/hostio.c b/gdb/gdbserver/hostio.c index 99014bc..df4cc78 100644 --- a/gdb/gdbserver/hostio.c +++ b/gdb/gdbserver/hostio.c @@ -134,7 +134,10 @@ require_data (char *p, int p_len, char **data, int *data_len) } if (escaped) - return -1; + { + xfree (data); + return -1; + } *data_len = output_index; return 0; |