aboutsummaryrefslogtreecommitdiffstats
path: root/dashboard/app/api.go
diff options
context:
space:
mode:
authorCheng-Min Chiang <chmnchiang@google.com>2020-09-02 17:23:49 -0700
committerDmitry Vyukov <dvyukov@google.com>2020-09-14 15:00:02 +0200
commit9eff3337ee5c407d4156eccb7bdea4d666e492fc (patch)
treea1e61c38d1d4f47bc7017a8e5c8e9d9b06fce6d8 /dashboard/app/api.go
parentdf4f5a9c4a22ded414b447d4d790c53d4d2a86e2 (diff)
dashboard/app: send machine information to dashboard
- Change syz-manager so that it will send machine info the first time a crash occurs. - Add a field in entities.Crash to store machine info. - Add a field in dashapi.BugReport to store machine info. - Change the HTML template and struct uiCrash to display machine info. - Add a test to make sure that the link to machine info appears on the webpage. Update #466
Diffstat (limited to 'dashboard/app/api.go')
-rw-r--r--dashboard/app/api.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/dashboard/app/api.go b/dashboard/app/api.go
index f30c87174..12f3c7e1c 100644
--- a/dashboard/app/api.go
+++ b/dashboard/app/api.go
@@ -810,6 +810,9 @@ func saveCrash(c context.Context, ns string, req *dashapi.Crash, bugKey *db.Key,
if crash.ReproC, err = putText(c, ns, textReproC, req.ReproC, false); err != nil {
return err
}
+ if crash.MachineInfo, err = putText(c, ns, textMachineInfo, req.MachineInfo, false); err != nil {
+ return err
+ }
crashKey := db.NewIncompleteKey(c, "Crash", bugKey)
if _, err = db.Put(c, crashKey, crash); err != nil {
return fmt.Errorf("failed to put crash: %v", err)