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

Side by Side Diff: content/browser/child_process_launcher_helper_android.cc

Issue 2706933003: webapk: Avoid overwriting default CreationParams
Patch Set: rebase 461342 Created 3 years, 8 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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "content/browser/child_process_launcher_helper_android.h" 5 #include "content/browser/child_process_launcher_helper_android.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/android/apk_assets.h" 9 #include "base/android/apk_assets.h"
10 #include "base/android/context_utils.h" 10 #include "base/android/context_utils.h"
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 ScopedJavaLocalRef<jobject> j_file_info = 124 ScopedJavaLocalRef<jobject> j_file_info =
125 Java_ChildProcessLauncherHelper_makeFdInfo(env, id, fd, auto_close, 125 Java_ChildProcessLauncherHelper_makeFdInfo(env, id, fd, auto_close,
126 region.offset, region.size); 126 region.offset, region.size);
127 PCHECK(j_file_info.obj()); 127 PCHECK(j_file_info.obj());
128 env->SetObjectArrayElement(j_file_infos.obj(), i, j_file_info.obj()); 128 env->SetObjectArrayElement(j_file_infos.obj(), i, j_file_info.obj());
129 if (auto_close) { 129 if (auto_close) {
130 ignore_result(files_to_register->ReleaseFD(fd).release()); 130 ignore_result(files_to_register->ReleaseFD(fd).release());
131 } 131 }
132 } 132 }
133 133
134 constexpr int param_key = 0; // TODO(boliu): Use this.
135 java_peer_.Reset(Java_ChildProcessLauncherHelper_create( 134 java_peer_.Reset(Java_ChildProcessLauncherHelper_create(
136 env, reinterpret_cast<intptr_t>(this), 135 env, reinterpret_cast<intptr_t>(this),
137 base::android::GetApplicationContext(), param_key, j_argv, 136 base::android::GetApplicationContext(), param_id_, j_argv,
138 child_process_id(), j_file_infos)); 137 child_process_id(), j_file_infos));
139 AddRef(); // Balanced by OnChildProcessStarted. 138 AddRef(); // Balanced by OnChildProcessStarted.
140 139
141 return Process(); 140 return Process();
142 } 141 }
143 142
144 void ChildProcessLauncherHelper::AfterLaunchOnLauncherThread( 143 void ChildProcessLauncherHelper::AfterLaunchOnLauncherThread(
145 const ChildProcessLauncherHelper::Process& process, 144 const ChildProcessLauncherHelper::Process& process,
146 const base::LaunchOptions& options) { 145 const base::LaunchOptions& options) {
147 } 146 }
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 } 238 }
240 } 239 }
241 240
242 } // namespace internal 241 } // namespace internal
243 242
244 bool RegisterChildProcessLauncher(JNIEnv* env) { 243 bool RegisterChildProcessLauncher(JNIEnv* env) {
245 return internal::RegisterNativesImpl(env); 244 return internal::RegisterNativesImpl(env);
246 } 245 }
247 246
248 } // namespace content 247 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/child_process_launcher_helper.cc ('k') | content/browser/frame_host/navigation_entry_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698