Skip to content

Commit 2db5411

Browse files
committed
fix(builder): return error from filepath.WalkDir in touchAutomakeFiles
Previously the error from WalkDir was silently discarded, now it is properly propagated to the caller. Signed-off-by: Martin Wimpress <code@wimpress.io>
1 parent bf8589c commit 2db5411

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

internal/builder/libraries.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -907,7 +907,7 @@ func touchAutomakeFiles(srcPath string) error {
907907
}
908908

909909
// Also touch any Makefile.in files in subdirectories
910-
filepath.WalkDir(srcPath, func(path string, d os.DirEntry, err error) error {
910+
return filepath.WalkDir(srcPath, func(path string, d os.DirEntry, err error) error {
911911
if err != nil {
912912
return err
913913
}
@@ -916,6 +916,4 @@ func touchAutomakeFiles(srcPath string) error {
916916
}
917917
return nil
918918
})
919-
920-
return nil
921919
}

0 commit comments

Comments
 (0)