diff options
author | Michael Snyder <msnyder@vmware.com> | 2011-03-10 20:09:18 +0000 |
---|---|---|
committer | Michael Snyder <msnyder@vmware.com> | 2011-03-10 20:09:18 +0000 |
commit | b2c044529986cbce7edaba8d5998609e625c0f38 (patch) | |
tree | 128452c98f2a3aa2b4a46a60c2594d62cf5163ca /gdb/gdbserver/server.c | |
parent | 197f0a605dde6bdc173692d9a8272940263ac108 (diff) | |
download | gdb-b2c044529986cbce7edaba8d5998609e625c0f38.zip gdb-b2c044529986cbce7edaba8d5998609e625c0f38.tar.gz gdb-b2c044529986cbce7edaba8d5998609e625c0f38.tar.bz2 |
2011-03-10 Michael Snyder <msnyder@vmware.com>
* gdbserver/server.c (handle_v_run): Free alloced buffer on early
return.
Diffstat (limited to 'gdb/gdbserver/server.c')
-rw-r--r-- | gdb/gdbserver/server.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/gdbserver/server.c b/gdb/gdbserver/server.c index 8a19809..2f4484f 100644 --- a/gdb/gdbserver/server.c +++ b/gdb/gdbserver/server.c @@ -1949,16 +1949,16 @@ handle_v_run (char *own_buf) if (program_argv == NULL) { - /* FIXME: new_argv memory leak */ write_enn (own_buf); + freeargv (new_argv); return 0; } new_argv[0] = strdup (program_argv[0]); if (new_argv[0] == NULL) { - /* FIXME: new_argv memory leak */ write_enn (own_buf); + freeargv (new_argv); return 0; } } |