X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/5b811fdb6d7fae96fa9fe45612dee560a64f2af6..d90a41491cfb04188c4469729fa60d01ec0ff693:/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);