logo

go-deblob

Remove binary blobs from a directory (deprecated, consider <https://git.sr.ht/~lanodan/deblob> instead) git clone https://hacktivis.me/git/go-deblob.git
commit: a7357e78aa13eab0683310abd4fc2a032fef1b36
parent e4f1c4ee81a5d0c40b13743f661c279c586b569b
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Thu, 23 Jun 2022 10:02:33 +0200

checkDir: defer dirFd.Close

Diffstat:

Mgo-deblob.go1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/go-deblob.go b/go-deblob.go @@ -63,6 +63,7 @@ func checkDir(dirname string, ignoring bool) { log.Printf("os.Open(%s): %s\n", dirname, err) return } + defer dirFd.Close(); files, err := dirFd.Readdir(0) if err != nil {