mirror of
				https://github.com/go-delve/delve.git
				synced 2025-10-31 18:57:18 +08:00 
			
		
		
		
	Don't rely on CurrentBreakpoint, lookup before continue
This commit is contained in:
		| @ -42,10 +42,14 @@ type Location struct { | ||||
| // first and then resume execution. Thread will continue until | ||||
| // it hits a breakpoint or is signaled. | ||||
| func (thread *Thread) Continue() error { | ||||
| 	pc, err := thread.PC() | ||||
| 	if err != nil { | ||||
| 		return err | ||||
| 	} | ||||
| 	// Check whether we are stopped at a breakpoint, and | ||||
| 	// if so, single step over it before continuing. | ||||
| 	if thread.CurrentBreakpoint != nil { | ||||
| 		if !thread.CurrentBreakpoint.hardware { | ||||
| 	if bp, ok := thread.dbp.FindBreakpoint(pc); ok { | ||||
| 		if !bp.hardware { | ||||
| 			if err := thread.Step(); err != nil { | ||||
| 				return err | ||||
| 			} | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Derek Parker
					Derek Parker