MCPcopy Create free account
hub / github.com/containerd/cgroups / readValue

Function readValue

cgroup1/cgroup_test.go:327–333  ·  view source on GitHub ↗
(mock *mockCgroup, path string)

Source from the content-addressed store, hash-verified

325}
326
327func readValue(mock *mockCgroup, path string) (string, error) {
328 data, err := os.ReadFile(filepath.Join(mock.root, path))
329 if err != nil {
330 return "", err
331 }
332 return string(data), nil
333}
334
335func checkPid(mock *mockCgroup, path string, expected int) error {
336 data, err := readValue(mock, filepath.Join(path, cgroupProcs))

Callers 3

checkPidFunction · 0.85
checkTaskidFunction · 0.85
TestCpusetParentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…