aboutsummaryrefslogtreecommitdiffstats
path: root/pkg
diff options
context:
space:
mode:
authorAleksandr Nogikh <nogikh@google.com>2024-07-17 17:41:12 +0200
committerAleksandr Nogikh <nogikh@google.com>2024-07-17 16:13:38 +0000
commit21615ebe39314f7e873e5acafe5e5b3f4331dac6 (patch)
tree5d2c51aee138532ba7742f5b72c8d7dfeb63d069 /pkg
parent877a6ab1caf7cf63a999580411cb395ab8ef058e (diff)
syz-manager: still ignore log parse problems
It seems that this error may come up in absolutely valid and reasonable cases. Restore the special casing.
Diffstat (limited to 'pkg')
-rw-r--r--pkg/repro/repro.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/pkg/repro/repro.go b/pkg/repro/repro.go
index 31958c8f7..bce3563e6 100644
--- a/pkg/repro/repro.go
+++ b/pkg/repro/repro.go
@@ -81,11 +81,13 @@ func Run(crashLog []byte, cfg *mgrconfig.Config, features flatrpc.Feature, repor
return ctx.run()
}
+var ErrEmptyCrashLog = errors.New("no programs")
+
func prepareCtx(crashLog []byte, cfg *mgrconfig.Config, features flatrpc.Feature, reporter *report.Reporter,
exec execInterface) (*reproContext, error) {
entries := cfg.Target.ParseLog(crashLog)
if len(entries) == 0 {
- return nil, fmt.Errorf("crash log (%d bytes) does not contain any programs", len(crashLog))
+ return nil, fmt.Errorf("log (%d bytes) parse failed: %w", len(crashLog), ErrEmptyCrashLog)
}
crashStart := len(crashLog)
crashTitle, crashType := "", crash.UnknownType