[client] Cleanup firewall state on startup (#2768)

This commit is contained in:
Viktor Liu
2024-10-24 14:46:24 +02:00
committed by GitHub
parent 4e918e55ba
commit 8016710d24
32 changed files with 739 additions and 318 deletions

View File

@@ -5,7 +5,7 @@ import (
"path/filepath"
"runtime"
"github.com/sirupsen/logrus"
log "github.com/sirupsen/logrus"
)
// GetDefaultStatePath returns the path to the state file based on the operating system
@@ -27,7 +27,7 @@ func GetDefaultStatePath() string {
dir := filepath.Dir(path)
if err := os.MkdirAll(dir, 0755); err != nil {
logrus.Errorf("Error creating directory %s: %v. Continuing without state support.", dir, err)
log.Errorf("Error creating directory %s: %v. Continuing without state support.", dir, err)
return ""
}