Eric Pouech : winedbg: In proxy mode, correctly init the wine_segs fields.

Alexandre Julliard julliard at winehq.org
Mon Nov 9 15:14:18 CST 2009


Module: wine
Branch: master
Commit: a116f78dedaf05a8b3f44bf5d56a5b76faaccacc
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=a116f78dedaf05a8b3f44bf5d56a5b76faaccacc

Author: Eric Pouech <eric.pouech at orange.fr>
Date:   Sun Nov  8 15:08:11 2009 +0100

winedbg: In proxy mode, correctly init the wine_segs fields.

---

 programs/winedbg/gdbproxy.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/programs/winedbg/gdbproxy.c b/programs/winedbg/gdbproxy.c
index 8afabe4..4794b06 100644
--- a/programs/winedbg/gdbproxy.c
+++ b/programs/winedbg/gdbproxy.c
@@ -1776,10 +1776,7 @@ static enum packet_return packet_query(struct gdb_context* gdbctx)
         {
             char    buf[64];
 
-            if (gdbctx->wine_segs[0] == 0 && gdbctx->wine_segs[1] == 0 &&
-                gdbctx->wine_segs[2] == 0)
-                return packet_error;
-            snprintf(buf, sizeof(buf), 
+            snprintf(buf, sizeof(buf),
                      "Text=%08lx;Data=%08lx;Bss=%08lx",
                      gdbctx->wine_segs[0], gdbctx->wine_segs[1],
                      gdbctx->wine_segs[2]);
@@ -2284,6 +2281,8 @@ static BOOL gdb_init_context(struct gdb_context* gdbctx, unsigned flags)
     gdbctx->process = NULL;
     for (i = 0; i < NUM_XPOINT; i++)
         gdbctx->Xpoints[i].type = -1;
+    for (i = 0; i < sizeof(gdbctx->wine_segs) / sizeof(gdbctx->wine_segs[0]); i++)
+        gdbctx->wine_segs[i] = 0;
 
     /* wait for first trap */
     while (WaitForDebugEvent(&de, INFINITE))




More information about the wine-cvs mailing list