runtime/pprof: fix typo in test

Not sure what I was thinking.

Change-Id: I143cdf7c5ef8e7b2394afeca6b30c46bb2c19a55
Reviewed-on: https://go-review.googlesource.com/33340
Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
Brad Fitzpatrick 2016-11-17 16:28:45 +00:00
parent 4ca3a8f7a8
commit afb0ae67b7

View file

@ -368,9 +368,9 @@ func getLinuxKernelConfig() string {
defer f.Close()
return slurpString(f)
}
uname, _ := exec.Command("uname, -r").Output()
uname, _ := exec.Command("uname", "-r").Output()
if len(uname) > 0 {
if f, err := os.Open("/boot/config-" + string(uname)); err == nil {
if f, err := os.Open("/boot/config-" + strings.TrimSpace(string(uname))); err == nil {
defer f.Close()
return slurpString(f)
}