diff options
author | Doug Evans <dje@google.com> | 2009-01-19 00:16:46 +0000 |
---|---|---|
committer | Doug Evans <dje@google.com> | 2009-01-19 00:16:46 +0000 |
commit | aef93bd75fcfdd562b7b7adc6ef66d8cbe13d99e (patch) | |
tree | b730067dd4ccff4b4c2b611d1458cad2c93bf521 /gdb/gdbserver/regcache.c | |
parent | a90b386908929431d254f92a0ecd8cc743b8be61 (diff) | |
download | fsf-binutils-gdb-aef93bd75fcfdd562b7b7adc6ef66d8cbe13d99e.zip fsf-binutils-gdb-aef93bd75fcfdd562b7b7adc6ef66d8cbe13d99e.tar.gz fsf-binutils-gdb-aef93bd75fcfdd562b7b7adc6ef66d8cbe13d99e.tar.bz2 |
* regcache.c (new_register_cache): No need to check result of xcalloc.
* server.c (handle_search_memory): Back out calls to xmalloc,
result is checked and error is returned to user upon failure.
(handle_query): Ditto. Add more checks for result of malloc.
(handle_v_cont): Check result of malloc, report error back to
user upon failure.
(handle_v_run): Ditto. Call freeargv.
* server.h (freeargv): Declare.
* utils.c (freeargv): New fn.
Diffstat (limited to 'gdb/gdbserver/regcache.c')
-rw-r--r-- | gdb/gdbserver/regcache.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/gdb/gdbserver/regcache.c b/gdb/gdbserver/regcache.c index 1454574..a050a4b 100644 --- a/gdb/gdbserver/regcache.c +++ b/gdb/gdbserver/regcache.c @@ -100,8 +100,6 @@ new_register_cache (void) in case there are registers the target never fetches. This way they'll read as zero instead of garbage. */ regcache->registers = xcalloc (1, register_bytes); - if (regcache->registers == NULL) - fatal ("Could not allocate register cache."); regcache->registers_valid = 0; |