|
@@ -81,7 +81,7 @@ type webArgs struct {
|
81
|
81
|
Top []report.TextItem
|
82
|
82
|
}
|
83
|
83
|
|
84
|
|
-func serveWebInterface(hostport string, p *profile.Profile, o *plugin.Options) error {
|
|
84
|
+func serveWebInterface(hostport string, p *profile.Profile, o *plugin.Options, wantBrowser bool) error {
|
85
|
85
|
host, portStr, err := net.SplitHostPort(hostport)
|
86
|
86
|
if err != nil {
|
87
|
87
|
return fmt.Errorf("could not split http address: %v", err)
|
|
@@ -123,7 +123,9 @@ func serveWebInterface(hostport string, p *profile.Profile, o *plugin.Options) e
|
123
|
123
|
},
|
124
|
124
|
}
|
125
|
125
|
|
126
|
|
- go openBrowser("http://"+args.Hostport, o)
|
|
126
|
+ if wantBrowser {
|
|
127
|
+ go openBrowser("http://"+args.Hostport, o)
|
|
128
|
+ }
|
127
|
129
|
return server(args)
|
128
|
130
|
}
|
129
|
131
|
|