[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 04/14] gdbstub: move mem_buf to GDBState and use GByteArra
From: |
Damien Hedde |
Subject: |
Re: [PATCH v2 04/14] gdbstub: move mem_buf to GDBState and use GByteArray |
Date: |
Tue, 3 Dec 2019 12:11:07 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.0 |
On 11/30/19 9:45 AM, Alex Bennée wrote:
> This is in preparation for further re-factoring of the register API
> with the rest of the code. Theoretically the read register function
> could overwrite the MAX_PACKET_LENGTH buffer although currently all
> registers are well within the size range.
>
> Signed-off-by: Alex Bennée <address@hidden>
> Reviewed-by: Richard Henderson <address@hidden>
> ---
> gdbstub.c | 62 ++++++++++++++++++++++++++++++++++---------------------
> 1 file changed, 38 insertions(+), 24 deletions(-)
>
> @@ -2003,7 +2015,7 @@ static void handle_query_curr_tid(GdbCmdContext
> *gdb_ctx, void *user_ctx)
> cpu = get_first_cpu_in_process(process);
> g_string_assign(gdbserver_state.str_buf, "QC");
> gdb_append_thread_id(cpu, gdbserver_state.str_buf);
> - put_strbuf();;
> + put_strbuf();
Hi Alex,
The double ';' (and the two other occurrences below) is added by your
previous patch.
> }
>
> static void handle_query_threads(GdbCmdContext *gdb_ctx, void *user_ctx)
> @@ -2015,7 +2027,7 @@ static void handle_query_threads(GdbCmdContext
> *gdb_ctx, void *user_ctx)
>
> g_string_assign(gdbserver_state.str_buf, "m");
> gdb_append_thread_id(gdbserver_state.query_cpu, gdbserver_state.str_buf);
> - put_strbuf();;
> + put_strbuf();
> gdbserver_state.query_cpu =
> gdb_next_attached_cpu(gdbserver_state.query_cpu);
> }
>
> @@ -2058,7 +2070,7 @@ static void handle_query_thread_extra(GdbCmdContext
> *gdb_ctx, void *user_ctx)
> }
> trace_gdbstub_op_extra_info(rs->str);
> memtohex(gdbserver_state.str_buf, (uint8_t *)rs->str, rs->len);
> - put_strbuf();;
> + put_strbuf();
> }
>
With the ";;" fix
Reviewed/Tested-by: Damien Hedde <damien.hedde@greensocs>
--
Damien
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH v2 04/14] gdbstub: move mem_buf to GDBState and use GByteArray,
Damien Hedde <=