Module: wine Branch: master Commit: 26aee726fb3dcf7615824cb51231964c04648eaa URL: https://source.winehq.org/git/wine.git/?a=commit;h=26aee726fb3dcf7615824cb51...
Author: Jinoh Kang jinoh.kang.kr@gmail.com Date: Wed Nov 24 00:10:01 2021 +0900
winedbg: Buffer output of GDB qXfer commands for proper slicing.
Today, gdbproxy reuses the same buffer for both the qXfer reply and the actual GDB packet reply. This worked well, since each byte in the qXfer reply buffer matched 1:1 to each byte in the actual GDB reply packet.
Since we escape special characters now, this property no longer holds and a single byte in qXfer reply will take up to two bytes in the GDB reply packet. This causes offsets to shift, preventing the offset/length response slicing (part of GDB protocol) from working correctly.
Fix this by writing the qXfer reply data in a separate buffer, and performing slicing out of it.
Signed-off-by: Jinoh Kang jinoh.kang.kr@gmail.com Signed-off-by: RĂ©mi Bernon rbernon@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
programs/winedbg/gdbproxy.c | 264 +++++++++++++++++++++++--------------------- 1 file changed, 137 insertions(+), 127 deletions(-)
Diff: https://source.winehq.org/git/wine.git/?a=commitdiff;h=26aee726fb3dcf7615824...