diff options
author | qsr@chromium.org <qsr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-16 15:02:33 +0000 |
---|---|---|
committer | qsr@chromium.org <qsr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-16 15:02:33 +0000 |
commit | 299eb28875c6c9ede63b7095cb2896f94ba7e0f3 (patch) | |
tree | 8f5950051158084b30fa924cad7509f2f321e2e8 /tools | |
parent | 105c0a9e41740034caa3e02a9c7ce3a9f45e66a2 (diff) | |
download | chromium_src-299eb28875c6c9ede63b7095cb2896f94ba7e0f3.zip chromium_src-299eb28875c6c9ede63b7095cb2896f94ba7e0f3.tar.gz chromium_src-299eb28875c6c9ede63b7095cb2896f94ba7e0f3.tar.bz2 |
Guard against no browser in the StopProfiling method.
If the browser failed to be created, a second exception is raised when
telemetry tries to stop profilers. This CL fixes this by checking for
the browser before trying to stop profilers.
R=bulach@chromium.org
BUG=307672
Review URL: https://codereview.chromium.org/27476005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@228917 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools')
-rw-r--r-- | tools/telemetry/telemetry/page/page_runner.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/telemetry/telemetry/page/page_runner.py b/tools/telemetry/telemetry/page/page_runner.py index 91ea615..c7be0c9 100644 --- a/tools/telemetry/telemetry/page/page_runner.py +++ b/tools/telemetry/telemetry/page/page_runner.py @@ -129,7 +129,8 @@ class _RunState(object): self.browser.StartProfiling(finder_options.profiler, output_file) def StopProfiling(self): - self.browser.StopProfiling() + if self.browser: + self.browser.StopProfiling() class PageState(object): |