X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/2f810149832a2d855c33d0df5b02d736c2081e41..b9734b132bcaf8a26ec1dbfcc71176e7182b5b0e:/src/xbt/win32_ucontext.c diff --git a/src/xbt/win32_ucontext.c b/src/xbt/win32_ucontext.c index c91c39e426..b6d5caf9fb 100644 --- a/src/xbt/win32_ucontext.c +++ b/src/xbt/win32_ucontext.c @@ -27,7 +27,7 @@ int getcontext(ucontext_t * ucp) int ret; /* Retrieve the full machine context */ - ucp->uc_mcontext.ContextFlags = CONTEXT_FULL; + ucp->uc_mcontext.ContextFlags = CONTEXT_FULL | CONTEXT_DEBUG_REGISTERS; ret = GetThreadContext(GetCurrentThread(), &ucp->uc_mcontext); return (ret == 0) ? -1 : 0; } @@ -59,7 +59,7 @@ int makecontext(ucontext_t * ucp, void (*func) (), int argc, ...) } /* Set the instruction and the stack pointer */ - #ifdef I_X86_ + #ifdef _I_X86_ ucp->uc_mcontext.Eip = (DWORD) func; ucp->uc_mcontext.Esp = (DWORD) sp - sizeof(void*); #endif @@ -72,7 +72,7 @@ int makecontext(ucontext_t * ucp, void (*func) (), int argc, ...) #endif /* Save/Restore the full machine context */ - ucp->uc_mcontext.ContextFlags = CONTEXT_FULL; + ucp->uc_mcontext.ContextFlags = CONTEXT_FULL | CONTEXT_DEBUG_REGISTERS; /* Copy the arguments */ va_start(ap, argc);