Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(116)

Side by Side Diff: chrome/browser/android/webapk/webapk_installer.cc

Issue 2409453002: Fix crash on WebAPK startup (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/android/webapk/webapk_installer.h" 5 #include "chrome/browser/android/webapk/webapk_installer.h"
6 6
7 #include "base/android/build_info.h" 7 #include "base/android/build_info.h"
8 #include "base/android/jni_android.h" 8 #include "base/android/jni_android.h"
9 #include "base/android/jni_string.h" 9 #include "base/android/jni_string.h"
10 #include "base/android/path_utils.h" 10 #include "base/android/path_utils.h"
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 } 485 }
486 486
487 void WebApkInstaller::OnSuccess() { 487 void WebApkInstaller::OnSuccess() {
488 FinishCallback callback = finish_callback_; 488 FinishCallback callback = finish_callback_;
489 std::string webapk_package = webapk_package_; 489 std::string webapk_package = webapk_package_;
490 delete this; 490 delete this;
491 callback.Run(true, webapk_package); 491 callback.Run(true, webapk_package);
492 } 492 }
493 493
494 void WebApkInstaller::OnFailure() { 494 void WebApkInstaller::OnFailure() {
495 FinishCallback callback = finish_callback_; 495 FinishCallback callback = finish_callback_;
dominickn 2016/10/10 06:05:38 Any particular reason this needs to be deleted bef
pkotwicz 2016/10/10 16:42:01 There is no particular reason. Changed as requeste
496 std::string webapk_package = webapk_package_;
496 delete this; 497 delete this;
497 callback.Run(false, ""); 498 callback.Run(false, webapk_package);
498 } 499 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698