• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

system/core


Commit MetaInfo

Revisionfb9270766f83901b76e1037a3f4c702eb102da00 (tree)
Time2019-11-16 06:04:30
AuthorWilliam Bellavance <flintman@flin...>
CommiterNolen Johnson

Log Message

init: don't skip starting a service with no domain if permissive

Requires external/libselinux change as well

Change-Id: I3f2887930e15d09014c2594141ba4acbbc8d6d9d

Change Summary

Incremental Difference

--- a/init/service.cpp
+++ b/init/service.cpp
@@ -373,9 +373,11 @@ bool Service::Start() {
373373 }
374374 if (rc == 0 && scon == mycon) {
375375 ERROR("Service %s does not have a SELinux domain defined.\n", name_.c_str());
376- free(mycon);
377- free(fcon);
378- return false;
376+ if (selinux_status_getenforce() > 0) {
377+ free(mycon);
378+ free(fcon);
379+ return false;
380+ }
379381 }
380382 free(mycon);
381383 free(fcon);