Search code examples
windowsdebuggingdynamic-library

Why breakpoint in user32.dll can't break another process


I set a breakpoint in user32!MessageBoxW, and this breakpoint only break my own process. If another also call MessageBoxW, it won't break at this breakpoint. Can anyone would like to tell me why? thanks a lot.


Solution

  • Breakpoint is typically implemented by replacing the instruction at the location of the breakpoint (see BreakPoint). That means your process is likely to use an altered version of the dll, said foo~.dll, but other process out side of your IDE are using the original foo.dll. That's why they won't break.