mirror of
https://github.com/go-delve/delve.git
synced 2025-11-01 12:01:35 +08:00
Remove unused function
This commit is contained in:
@ -4,8 +4,7 @@ import (
|
||||
"bytes"
|
||||
"encoding/binary"
|
||||
"fmt"
|
||||
"os"
|
||||
"strconv"
|
||||
|
||||
"syscall"
|
||||
|
||||
"github.com/derekparker/delve/dwarf/frame"
|
||||
@ -314,30 +313,3 @@ func (thread *ThreadContext) clearTempBreakpoint(pc uint64) error {
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func threadIds(pid int) []int {
|
||||
var threads []int
|
||||
dir, err := os.Open(fmt.Sprintf("/proc/%d/task", pid))
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
defer dir.Close()
|
||||
|
||||
names, err := dir.Readdirnames(0)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
for _, strid := range names {
|
||||
tid, err := strconv.Atoi(strid)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
if tid != pid {
|
||||
threads = append(threads, tid)
|
||||
}
|
||||
}
|
||||
|
||||
return threads
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user