diff options
author | Mark Salyzyn <salyzyn@google.com> | 2015-04-20 10:27:38 -0700 |
---|---|---|
committer | Mark Salyzyn <salyzyn@google.com> | 2015-05-05 12:34:16 -0700 |
commit | aa43ae2268076227e8b72ea095f8aeac439b3168 (patch) | |
tree | 8ecfe5a66a0c28517bd04a54c2d4cac0a6ed7d87 /logd | |
parent | aaf9c1b3b489de6b07b5a1a0ad9b6cbbb9b56782 (diff) | |
download | core-aa43ae2268076227e8b72ea095f8aeac439b3168.tar.gz core-aa43ae2268076227e8b72ea095f8aeac439b3168.tar.bz2 core-aa43ae2268076227e8b72ea095f8aeac439b3168.zip |
logd: pidToName deficiency
any logging in zygote permanently sets the pidToName
Change-Id: I0b8fdc96fb5965a04d4dc4293c39815beef5eb8e
Diffstat (limited to 'logd')
-rw-r--r-- | logd/LogStatistics.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/logd/LogStatistics.h b/logd/LogStatistics.h index a935c2702..ca4b9a6bf 100644 --- a/logd/LogStatistics.h +++ b/logd/LogStatistics.h @@ -186,6 +186,10 @@ struct PidEntry : public EntryBaseDropped { const char*getName() const { return name; } inline void add(pid_t p) { + if (name && !strncmp(name, "zygote", 6)) { + free(name); + name = NULL; + } if (!name) { char *n = android::pidToName(p); if (n) { |