Fix incorrect return in finally block losing exceptions.
Returning in a finally block causes exceptions to be discarded. There's no reason to log a UMA stat for the performance of a startup that threw an exception (since we're going to crash the app anyway), so just take it entirely outside the finally block and invert the condition to only record the UMA stat if mFactory.hasStarted(). Also adjust another place that had the same pattern without the "return" to match, as again there's no need to log the UMA stat when there's an exception. Bug: 862662 Change-Id: Ie6d24cee5bb9342016c364244256c8b73a8184f7 Reviewed-on: https://chromium-review.googlesource.com/1133332 Commit-Queue: Richard Coles <torne@chromium.org> Reviewed-by:Tobias Sargeant <tobiasjs@chromium.org> Cr-Commit-Position: refs/heads/master@{#574941}
Showing
Please register or sign in to comment