1
1
Fork 0
mirror of https://tildegit.org/solderpunk/molly-brown synced 2024-04-28 12:55:28 +02:00

Whoops, don't ignore error from filepath.Abs.

This commit is contained in:
Solderpunk 2023-02-15 21:15:14 +01:00
parent 8372142843
commit c0c67f7ba6

View File

@ -96,7 +96,10 @@ func getConfig(filename string) (Config, error) {
// Validate chroot() dir
if config.ChrootDir != "" {
config.ChrootDir = filepath.Abs(config.ChrootDir)
config.ChrootDir, err = filepath.Abs(config.ChrootDir)
if err != nil {
return config, err
}
_, err := os.Stat(config.ChrootDir)
if os.IsNotExist(err) {
return config, err