mirror of
https://github.com/reactos/syzkaller.git
synced 2025-02-04 18:56:16 +00:00
syz-manager: fix repro saving
If manager is connected to dashboard it now does not save crashes. Which means that when we save a repro the crash dir may not exist yet. Create the dir when saving repros.
This commit is contained in:
parent
240b07788c
commit
0bdcc49799
@ -608,6 +608,7 @@ func (mgr *Manager) saveFailedRepro(desc string) {
|
||||
}
|
||||
}
|
||||
dir := filepath.Join(mgr.crashdir, hash.String([]byte(desc)))
|
||||
osutil.MkdirAll(dir)
|
||||
for i := 0; i < maxReproAttempts; i++ {
|
||||
name := filepath.Join(dir, fmt.Sprintf("repro%v", i))
|
||||
if !osutil.IsExist(name) {
|
||||
@ -620,6 +621,7 @@ func (mgr *Manager) saveFailedRepro(desc string) {
|
||||
func (mgr *Manager) saveRepro(res *repro.Result) {
|
||||
res.Report = mgr.symbolizeReport(res.Report)
|
||||
dir := filepath.Join(mgr.crashdir, hash.String([]byte(res.Desc)))
|
||||
osutil.MkdirAll(dir)
|
||||
|
||||
opts := fmt.Sprintf("# %+v\n", res.Opts)
|
||||
prog := res.Prog.Serialize()
|
||||
|
Loading…
x
Reference in New Issue
Block a user