之前版本中通過屬性來啟動(dòng)服務(wù)失效了
是在P上對(duì)屬性名進(jìn)行了規(guī)范,必現(xiàn)符合規(guī)則的才可以
具體的修改提交如下
diff --git[a/init/action_parser.cpp](https://android.googlesource.com/platform/system/core/+/dd85c74655400347aee5f6bfecd827a311f16ca4/init/action_parser.cpp)[b/init/action_parser.cpp]
(https://android.googlesource.com/platform/system/core/+/fa79ae87f12d2709482375f56a1c13737a8513f3/init/action_parser.cpp)
index 2d497b3..4f8bd16 100644
--- a/init/action_parser.cpp
+++ b/init/action_parser.cpp
@@ -40,6 +40,18 @@
return true; }
+ static constexpr const char* kPartnerPrefixes[] = {
+ "init.svc.vendor.", "ro.vendor.", "persist.vendor.",+ "vendor.", "init.svc.odm.", "ro.odm.",
+ "persist.odm.", "odm.", "ro.boot.",+ };
++ for (const auto& prefix : kPartnerPrefixes) {
+ if (android::base::StartsWith(prop_name, prefix)) {
+ return true;+ }
+ }
+ return CanReadProperty(subcontext->context(), prop_name); }