diff --git a/warn/warn.go b/warn/warn.go index 8d299de80..6f7c24e51 100644 --- a/warn/warn.go +++ b/warn/warn.go @@ -336,7 +336,8 @@ func FileWarnings(f *build.File, enabledWarnings []string, formatted *[]byte, mo } else if fct, ok := RuleWarningMap[warn]; ok { findings = append(findings, runWarningsFunction(warn, f, ruleWarningWrapper(fct), formatted, mode, fileReader)...) } else { - log.Fatalf("unexpected warning %q", warn) + log.Printf("unexpected warning %q", warn) + os.Exit(1) } } sort.Slice(findings, func(i, j int) bool { return findings[i].Start.Line < findings[j].Start.Line })