mirror of
https://github.com/reactos/syzkaller.git
synced 2024-11-27 13:20:34 +00:00
syz-manager/mgrconfig: fix selection of executor binary
We currently select executor for vm arch, need to select target arch. This breaks linux/amd64/386 configuration where we select amd64 instead of 386.
This commit is contained in:
parent
296be8cc8d
commit
441d64d9a5
@ -109,16 +109,16 @@ func load(data []byte, filename string) (*Config, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
targetBin := func(name string) string {
|
||||
targetBin := func(name, arch string) string {
|
||||
exe := ""
|
||||
if cfg.TargetOS == "windows" {
|
||||
exe = ".exe"
|
||||
}
|
||||
return filepath.Join(cfg.Syzkaller, "bin", cfg.TargetOS+"_"+cfg.TargetVMArch, name+exe)
|
||||
return filepath.Join(cfg.Syzkaller, "bin", cfg.TargetOS+"_"+arch, name+exe)
|
||||
}
|
||||
cfg.SyzFuzzerBin = targetBin("syz-fuzzer")
|
||||
cfg.SyzExecprogBin = targetBin("syz-execprog")
|
||||
cfg.SyzExecutorBin = targetBin("syz-executor")
|
||||
cfg.SyzFuzzerBin = targetBin("syz-fuzzer", cfg.TargetVMArch)
|
||||
cfg.SyzExecprogBin = targetBin("syz-execprog", cfg.TargetVMArch)
|
||||
cfg.SyzExecutorBin = targetBin("syz-executor", cfg.TargetArch)
|
||||
if !osutil.IsExist(cfg.SyzFuzzerBin) {
|
||||
return nil, fmt.Errorf("bad config syzkaller param: can't find %v", cfg.SyzFuzzerBin)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user