summaryrefslogtreecommitdiff
path: root/libnativeloader/library_namespaces.cpp
diff options
context:
space:
mode:
author Martin Stjernholm <mast@google.com> 2022-09-13 23:10:12 +0100
committer Martin Stjernholm <mast@google.com> 2022-09-14 16:02:07 +0000
commit81b3f56cab037577dfa1c53024145a4385df5ca1 (patch)
tree32792978117d37363dced8aaa1bdfe2d7fdc75eb /libnativeloader/library_namespaces.cpp
parent778800e334a3fd0f29dbeabad114032bc849a9d1 (diff)
Clarify that is_shared in practice gives access to system libs for
system apps. Test: n/a - comment change only Bug: 237577392 Change-Id: I12a2d731fd3b8bff908e8bd363b105d0eb8ad7f8
Diffstat (limited to 'libnativeloader/library_namespaces.cpp')
-rw-r--r--libnativeloader/library_namespaces.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/libnativeloader/library_namespaces.cpp b/libnativeloader/library_namespaces.cpp
index d49420f313..aaf724153f 100644
--- a/libnativeloader/library_namespaces.cpp
+++ b/libnativeloader/library_namespaces.cpp
@@ -245,10 +245,11 @@ Result<NativeLoaderNamespace*> LibraryNamespaces::Create(JNIEnv* env, uint32_t t
if (!is_shared) {
if (apk_origin == APK_ORIGIN_SYSTEM) {
- // System apps commonly get shared namespaces and hence don't need this.
- // In practice it's necessary for shared system libraries (i.e. JARs
- // rather than actual APKs) that are loaded by ordinary apps which don't
- // get shared namespaces.
+ // System apps commonly get access to system libs from the system
+ // namespace through shared namespaces (i.e. is_shared is true) and hence
+ // don't need this. In practice it's necessary for shared system libraries
+ // (i.e. JARs rather than actual APKs) that are loaded by ordinary apps
+ // which don't get shared namespaces.
apk_origin_msg = "system apk";
// Give access to all libraries in the system and system_ext partitions