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

Side by Side Diff: content/app/android/child_process_service.cc

Issue 141223002: Move the android library loader from content to base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix final nits Created 6 years, 10 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/app/android/child_process_service.h" 5 #include "content/app/android/child_process_service.h"
6 6
7 #include <android/native_window_jni.h> 7 #include <android/native_window_jni.h>
8 #include <cpu-features.h> 8 #include <cpu-features.h>
9 9
10 #include "base/android/jni_array.h" 10 #include "base/android/jni_array.h"
11 #include "base/android/library_loader/library_loader_hooks.h"
11 #include "base/android/memory_pressure_listener_android.h" 12 #include "base/android/memory_pressure_listener_android.h"
12 #include "base/logging.h" 13 #include "base/logging.h"
13 #include "base/posix/global_descriptors.h" 14 #include "base/posix/global_descriptors.h"
14 #include "content/child/child_thread.h" 15 #include "content/child/child_thread.h"
15 #include "content/common/android/surface_texture_peer.h" 16 #include "content/common/android/surface_texture_peer.h"
16 #include "content/common/gpu/gpu_surface_lookup.h" 17 #include "content/common/gpu/gpu_surface_lookup.h"
17 #include "content/public/app/android_library_loader_hooks.h" 18 #include "content/public/app/android_library_loader_hooks.h"
18 #include "content/public/common/content_descriptors.h" 19 #include "content/public/common/content_descriptors.h"
19 #include "ipc/ipc_descriptors.h" 20 #include "ipc/ipc_descriptors.h"
20 #include "jni/ChildProcessService_jni.h" 21 #include "jni/ChildProcessService_jni.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 JavaIntArrayToIntVector(env, j_file_ids, &file_ids); 121 JavaIntArrayToIntVector(env, j_file_ids, &file_ids);
121 JavaIntArrayToIntVector(env, j_file_fds, &file_fds); 122 JavaIntArrayToIntVector(env, j_file_fds, &file_fds);
122 123
123 InternalInitChildProcess( 124 InternalInitChildProcess(
124 file_ids, file_fds, env, clazz, context, service, 125 file_ids, file_fds, env, clazz, context, service,
125 cpu_count, cpu_features); 126 cpu_count, cpu_features);
126 } 127 }
127 128
128 void ExitChildProcess(JNIEnv* env, jclass clazz) { 129 void ExitChildProcess(JNIEnv* env, jclass clazz) {
129 VLOG(0) << "ChildProcessService: Exiting child process."; 130 VLOG(0) << "ChildProcessService: Exiting child process.";
130 LibraryLoaderExitHook(); 131 base::android::LibraryLoaderExitHook();
131 _exit(0); 132 _exit(0);
132 } 133 }
133 134
134 bool RegisterChildProcessService(JNIEnv* env) { 135 bool RegisterChildProcessService(JNIEnv* env) {
135 return RegisterNativesImpl(env); 136 return RegisterNativesImpl(env);
136 } 137 }
137 138
138 void ShutdownMainThread(JNIEnv* env, jobject obj) { 139 void ShutdownMainThread(JNIEnv* env, jobject obj) {
139 ChildThread::ShutdownThread(); 140 ChildThread::ShutdownThread();
140 } 141 }
141 142
142 } // namespace content 143 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698