diff options
| author | dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> | 2023-07-21 10:41:17 +0000 |
|---|---|---|
| committer | Taras Madan <tarasmadan@google.com> | 2023-07-24 06:24:36 +0000 |
| commit | b03242d7ab98645d2c936e1899aac9f0aeb9813e (patch) | |
| tree | 4f74d0da1ea42a38a125b3a972b44c434b2a38fa /vendor/github.com/prometheus/procfs/internal | |
| parent | f0f7d1e0a67964f4733690290b236755148b8188 (diff) | |
mod: do: bump github.com/prometheus/client_golang from 1.14.0 to 1.16.0
Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.14.0 to 1.16.0.
- [Release notes](https://github.com/prometheus/client_golang/releases)
- [Changelog](https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prometheus/client_golang/compare/v1.14.0...v1.16.0)
---
updated-dependencies:
- dependency-name: github.com/prometheus/client_golang
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Diffstat (limited to 'vendor/github.com/prometheus/procfs/internal')
| -rw-r--r-- | vendor/github.com/prometheus/procfs/internal/util/parse.go | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/vendor/github.com/prometheus/procfs/internal/util/parse.go b/vendor/github.com/prometheus/procfs/internal/util/parse.go index b030951fa..14272dc78 100644 --- a/vendor/github.com/prometheus/procfs/internal/util/parse.go +++ b/vendor/github.com/prometheus/procfs/internal/util/parse.go @@ -64,6 +64,21 @@ func ParsePInt64s(ss []string) ([]*int64, error) { return us, nil } +// Parses a uint64 from given hex in string. +func ParseHexUint64s(ss []string) ([]*uint64, error) { + us := make([]*uint64, 0, len(ss)) + for _, s := range ss { + u, err := strconv.ParseUint(s, 16, 64) + if err != nil { + return nil, err + } + + us = append(us, &u) + } + + return us, nil +} + // ReadUintFromFile reads a file and attempts to parse a uint64 from it. func ReadUintFromFile(path string) (uint64, error) { data, err := os.ReadFile(path) |
