Skip to content

Commit

Permalink
cmd/trace: don't fail when no browser is available
Browse files Browse the repository at this point in the history
When there is no browser available on the system,
we should print the URL instead of failing.

Change-Id: I4a2b099e17609394273eff150062c285d76bbac1
Reviewed-on: https://go-review.googlesource.com/13774
Reviewed-by: Dmitry Vyukov <[email protected]>
  • Loading branch information
0intro committed Aug 21, 2015
1 parent 13b5dc8 commit 9538e4e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cmd/trace/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func main() {
}
// Open browser.
if !startBrowser("http://" + ln.Addr().String()) {
dief("failed to start browser\n")
fmt.Fprintf(os.Stderr, "Trace viewer is listening on http://%s\n", ln.Addr().String())
}

// Parse and symbolize trace asynchronously while browser opens.
Expand Down

0 comments on commit 9538e4e

Please sign in to comment.