[prev in list] [next in list] [prev in thread] [next in thread]
List: gdb-patches
Subject: Re: [PATCH 3/6] Use simple_search_memory in gdbserver
From: Simon Marchi <simark () simark ! ca>
Date: 2020-07-30 13:01:43
Message-ID: 2a1fc949-3ffb-6b2a-d22f-ee3237317025 () simark ! ca
[Download RAW message or body]
On 2020-07-23 4:12 p.m., Tom Tromey wrote:
> @@ -1158,25 +1069,13 @@ handle_search_memory (char *own_buf, int packet_len)
> return;
> }
>
> - search_buf_size = chunk_size + pattern_len - 1;
> -
> - /* No point in trying to allocate a buffer larger than the search space. */
> - if (search_space_len < search_buf_size)
> - search_buf_size = search_space_len;
> -
> - search_buf = (gdb_byte *) malloc (search_buf_size);
> - if (search_buf == NULL)
> + auto read_memory = [=] (CORE_ADDR addr, gdb_byte *result, size_t len)
The capture is not needed here.
Simon
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic