From 88cdd71d7e0294e440822b4e2ed8cb5f7e543411 Mon Sep 17 00:00:00 2001 From: Mark Salyzyn <salyzyn@google.com> Date: Mon, 3 Apr 2017 12:38:30 -0700 Subject: [PATCH] logcatd: introduce logcatd executable logcatd is the same as logcat, except that the -L flag, if supplied, runs once, then the command re-runs itself without the -L flag with the same argument set. By introducing a logcatd daemon executable we can solve the problem of the longish reads from pstore that sometimes occur when the system is excessively busy spinning in a foreground task starving this daemon as we absorb the delay in an init service, rather than in an init exec. This would not have been efficiently possible without the introduction of liblogcat. Test: gTest logcat-unit-tests Test: Manual check logpersist operations Bug: 28788401 Bug: 30041146 Bug: 30612424 Bug: 35326290 Change-Id: I3454bad666c66663f59ae03bcd72e0fe8426bb0a --- private/file_contexts | 1 + 1 file changed, 1 insertion(+) diff --git a/private/file_contexts b/private/file_contexts index bd111b808..4a392f1c2 100644 --- a/private/file_contexts +++ b/private/file_contexts @@ -173,6 +173,7 @@ /system/bin/toolbox -- u:object_r:toolbox_exec:s0 /system/bin/toybox -- u:object_r:toolbox_exec:s0 /system/bin/logcat -- u:object_r:logcat_exec:s0 +/system/bin/logcatd -- u:object_r:logcat_exec:s0 /system/bin/sh -- u:object_r:shell_exec:s0 /system/bin/run-as -- u:object_r:runas_exec:s0 /system/bin/bootanimation u:object_r:bootanim_exec:s0 -- GitLab