mirror of
https://github.com/go-delve/delve.git
synced 2025-10-28 04:35:19 +08:00
pkg/proc: Refactor process post initialization
This patch is a slight refactor to share more code used for genericprocess initialization. There will always be OS/backend specificinitialization, but as much as can be shared should be to preventduplicating of any logic (setting internal breakpoints, loading bininfo,etc).
This commit is contained in:
committed by
Alessandro Arzilli
parent
91953dd49c
commit
d61cd1c0d7
@ -174,7 +174,7 @@ func withCoreFile(t *testing.T, name, args string) *Process {
|
||||
|
||||
p, err := OpenCore(corePath, fix.Path, []string{})
|
||||
if err != nil {
|
||||
t.Errorf("ReadCore(%q) failed: %v", corePath, err)
|
||||
t.Errorf("OpenCore(%q) failed: %v", corePath, err)
|
||||
pat, err := ioutil.ReadFile("/proc/sys/kernel/core_pattern")
|
||||
t.Errorf("read core_pattern: %q, %v", pat, err)
|
||||
apport, err := ioutil.ReadFile("/var/log/apport.log")
|
||||
|
||||
Reference in New Issue
Block a user