qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 10/12] gdbstub: refactor get_feature_xml


From: Richard Henderson
Subject: Re: [PATCH v3 10/12] gdbstub: refactor get_feature_xml
Date: Tue, 29 Aug 2023 15:18:51 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0

On 8/29/23 09:15, Alex Bennée wrote:
Try to bring up the code to more modern standards by:

   - use dynamic GString built xml over a fixed buffer
   - use autofree to save on explicit g_free() calls
   - don't hand hack strstr to find the delimiter
   - fix up style of xml_builtin and invert loop

Signed-off-by: Alex Bennée<alex.bennee@linaro.org>

---
v3
   - also clean-up xml_builtin loop
   - use strchr and defere copy for only xml case
v2
   - avoid needless g_strndup for copy of annex
---
  gdbstub/internals.h |  2 +-
  gdbstub/gdbstub.c   | 81 +++++++++++++++++++++++----------------------
  2 files changed, 43 insertions(+), 40 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]