parent
ee3d7e8d55
commit
d06abe3f2f
@ -91,6 +91,11 @@ func (d *Debugger) Restart() error {
|
||||
if err != nil {
|
||||
return fmt.Errorf("could not launch process: %s", err)
|
||||
}
|
||||
for addr, _ := range d.process.Breakpoints {
|
||||
if _, err := p.SetBreakpoint(addr); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
d.process = p
|
||||
return nil
|
||||
}
|
||||
|
@ -101,12 +101,8 @@ func TestRestart_duringStop(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
if len(bps) != 0 {
|
||||
t.Fatal("breakpoint tabe not cleared")
|
||||
}
|
||||
state = <-c.Continue()
|
||||
if !state.Exited {
|
||||
t.Fatal("expected process to have exited")
|
||||
if len(bps) == 0 {
|
||||
t.Fatal("breakpoints not preserved")
|
||||
}
|
||||
})
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user