diff options
author | Felipe Leme <felipeal@google.com> | 2016-07-28 13:26:07 -0700 |
---|---|---|
committer | Felipe Leme <felipeal@google.com> | 2016-07-28 14:11:32 -0700 |
commit | c64c982e729e4c4ff5c7d1878488ed216738d443 (patch) | |
tree | 8b7bc7e0b9e4b168a591fb9ca9e65d5a283a3817 | |
parent | cd42d658b2d08ace81b5ae3b108acbaca1a1d439 (diff) | |
download | core-c64c982e729e4c4ff5c7d1878488ed216738d443.tar.gz core-c64c982e729e4c4ff5c7d1878488ed216738d443.tar.bz2 core-c64c982e729e4c4ff5c7d1878488ed216738d443.zip |
Improved keychord logging.
Often a bugreport is accidentally triggered by the combo keys, but there
is nothing in the bugreport to confirm that action because init's
klog level is KLOG_NOTICE_LEVEL.
This change change keychord's INFO messages to NOTICE, and also logs the
case where a service was not launched because ADB was disabled.
BUG: 30440213
BUG: 30345559
Change-Id: I6ccadef1621cb41dcd15e7c1660366f0e147dc7a
-rw-r--r-- | init/keychords.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/init/keychords.cpp b/init/keychords.cpp index 7a7838dd3..1468c5703 100644 --- a/init/keychords.cpp +++ b/init/keychords.cpp @@ -78,11 +78,13 @@ static void handle_keychord() { if (adb_enabled == "running") { Service* svc = ServiceManager::GetInstance().FindServiceByKeychord(id); if (svc) { - INFO("Starting service %s from keychord\n", svc->name().c_str()); + NOTICE("Starting service '%s' from keychord %d\n", svc->name().c_str(), id); svc->Start(); } else { - ERROR("service for keychord %d not found\n", id); + ERROR("Service for keychord %d not found\n", id); } + } else { + WARNING("Not starting service for keychord %d because ADB is disabled\n", id); } } |