aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Vyukov <dvyukov@google.com>2014-02-10 13:52:58 +0400
committerDmitriy Vyukov <dvyukov@google.com>2014-02-10 13:52:58 +0400
commitfa3a2a84cc2f4aa10ddb2a205e9fb0656d46ff83 (patch)
tree223913e21d8fc4f0ae3b0a114f23f0430cb8c71c
parentff5f9bbf6a5d5281a2bf5326ce43df65deef4ac1 (diff)
downloadgo-fa3a2a84cc2f4aa10ddb2a205e9fb0656d46ff83.tar.xz
misc/pprof: support web profiles on windows
LGTM=bradfitz R=golang-codereviews, bradfitz, alex.brainman CC=golang-codereviews https://golang.org/cl/61260044
-rwxr-xr-xmisc/pprof7
1 files changed, 7 insertions, 0 deletions
diff --git a/misc/pprof b/misc/pprof
index 1fc8d36219..713c3620fc 100755
--- a/misc/pprof
+++ b/misc/pprof
@@ -730,6 +730,13 @@ sub RunWeb {
return;
}
+ if (`uname` =~ /CYGWIN/) {
+ # Windows(cygwin): open will use standard preference for SVG files.
+ my $winname = `cygpath -wa $fname`;
+ system("explorer.exe", $winname);
+ return;
+ }
+
# Some kind of Unix; try generic symlinks, then specific browsers.
# (Stop once we find one.)
# Works best if the browser is already running.