MCPcopy Create free account
hub / github.com/google/pprof / cleanupTempFiles

Function cleanupTempFiles

internal/driver/tempfile.go:49–60  ·  view source on GitHub ↗

cleanupTempFiles removes any temporary files selected for deferred cleaning.

()

Source from the content-addressed store, hash-verified

47
48// cleanupTempFiles removes any temporary files selected for deferred cleaning.
49func cleanupTempFiles() error {
50 tempFilesMu.Lock()
51 defer tempFilesMu.Unlock()
52 var lastErr error
53 for _, f := range tempFiles {
54 if err := os.Remove(f); err != nil {
55 lastErr = err
56 }
57 }
58 tempFiles = nil
59 return lastErr
60}

Callers 2

TestNewTempFileFunction · 0.85
PProfFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestNewTempFileFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…