diff --git a/main.go b/main.go index b8728910..7d8291b3 100644 --- a/main.go +++ b/main.go @@ -714,8 +714,10 @@ This flag can be passed multiple times to ignore different vulnerabilities`) return 1 } - // note: we are writing out temp files which should be cleaned up after you're done with the image object - defer img.Cleanup() + defer func() { + stereoscope.Cleanup() + _ = img.Cleanup() + }() } pathsToLocks, errored := findAllLockfiles(r, cli.Args(), *parseAs, img)