aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/vendor/github.com/google/pprof/internal/elfexec
diff options
context:
space:
mode:
authorEmmanuel T Odeke <emmanuel@orijtech.com>2024-05-27 21:07:22 -0600
committerGopher Robot <gobot@golang.org>2024-05-31 19:48:28 +0000
commit9b43bfbc51c469ec13fca24960834a75b2bf66eb (patch)
treecafe177d5e024ae1a903f9c69824ed99ee673082 /src/cmd/vendor/github.com/google/pprof/internal/elfexec
parent00b8071a12e298303b2f4bd0e9f641ef3e54772a (diff)
downloadgo-9b43bfbc51c469ec13fca24960834a75b2bf66eb.tar.xz
cmd/vendor: update github.com/google/pprof
Brings in the latest github.com/google/pprof. Fixes #67626 Change-Id: Id8faef20f0a9bf81dd117110bf540aca852db6be Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest Reviewed-on: https://go-review.googlesource.com/c/go/+/588655 Reviewed-by: Carlos Amedee <carlos@golang.org> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Diffstat (limited to 'src/cmd/vendor/github.com/google/pprof/internal/elfexec')
-rw-r--r--src/cmd/vendor/github.com/google/pprof/internal/elfexec/elfexec.go7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/cmd/vendor/github.com/google/pprof/internal/elfexec/elfexec.go b/src/cmd/vendor/github.com/google/pprof/internal/elfexec/elfexec.go
index 718481b078..10436a2256 100644
--- a/src/cmd/vendor/github.com/google/pprof/internal/elfexec/elfexec.go
+++ b/src/cmd/vendor/github.com/google/pprof/internal/elfexec/elfexec.go
@@ -118,12 +118,7 @@ func parseNotes(reader io.Reader, alignment int, order binary.ByteOrder) ([]elfN
//
// If no build-ID was found but the binary was read without error, it returns
// (nil, nil).
-func GetBuildID(binary io.ReaderAt) ([]byte, error) {
- f, err := elf.NewFile(binary)
- if err != nil {
- return nil, err
- }
-
+func GetBuildID(f *elf.File) ([]byte, error) {
findBuildID := func(notes []elfNote) ([]byte, error) {
var buildID []byte
for _, note := range notes {