Merge pull request #12557 from vrothberg/fix-11825

inotify: make sure to remove files
This commit is contained in:
OpenShift Merge Robot 2021-12-09 17:45:22 +00:00 committed by GitHub
commit 9cfdffdfa3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -56,6 +56,7 @@ func WaitForFile(path string, chWait chan error, timeout time.Duration) (bool, e
inotifyEvents = watcher.Events
}
defer watcher.Close()
defer watcher.Remove(filepath.Dir(path))
}
var timeoutChan <-chan time.Time