From 49bd8837c4708048e876a8c494ab4ebd36089bb1 Mon Sep 17 00:00:00 2001 From: Qilong Zhang Date: Wed, 4 May 2022 18:25:33 +0800 Subject: [PATCH] appspwan:add new medialibrary hap Signed-off-by: Qilong Zhang Change-Id: I92e7ee4ced0d7e38468c7c4d279dd49906ad3f6f --- appdata-sandbox.json | 12 ++++++++++++ standard/appspawn_service.c | 3 ++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/appdata-sandbox.json b/appdata-sandbox.json index dc5f608c..058bad9f 100644 --- a/appdata-sandbox.json +++ b/appdata-sandbox.json @@ -146,6 +146,18 @@ ], "symbol-links" : [] }], + "com.ohos.medialibrary.medialibrarydata" : [{ + "sandbox-switch": "ON", + "sandbox-root" : "/mnt/sandbox/", + "mount-bind-paths" : [{ + "src-path" : "/storage/media/", + "sandbox-path" : "/storage/media", + "sandbox-flags" : [ "bind", "rec" ], + "check-action-status": "false" + } + ], + "symbol-links" : [] + }], "com.ohos.launcher" : [{ "sandbox-switch": "ON", "sandbox-root" : "/mnt/sandbox/", diff --git a/standard/appspawn_service.c b/standard/appspawn_service.c index ebfc10c4..6da9f563 100644 --- a/standard/appspawn_service.c +++ b/standard/appspawn_service.c @@ -169,7 +169,8 @@ static void HandleSpecial(AppSpawnClientExt *appProperty) // special handle bundle name medialibrary and scanner const char *specialBundleNames[] = { "com.ohos.medialibrary.MediaLibraryDataA", - "com.ohos.medialibrary.MediaScannerAbilityA" + "com.ohos.medialibrary.MediaScannerAbilityA", + "com.ohos.medialibrary.medialibrarydata" }; for (size_t i = 0; i < sizeof(specialBundleNames) / sizeof(specialBundleNames[0]); i++) { if (strcmp(appProperty->property.processName, specialBundleNames[i]) == 0) { -- Gitee