aboutsummaryrefslogtreecommitdiffstats
path: root/libc/bionic/logd_write.c
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2013-01-17 18:36:06 -0800
committerElliott Hughes <enh@google.com>2013-01-18 22:20:06 -0800
commit1e980b6bc8315d00a07312b25486531247abd98c (patch)
tree539f2c0c63fca27d5eb6ba184d658bb0e11a32d9 /libc/bionic/logd_write.c
parente4ca88d9fa8757e4fb4056fcafa5bc15b406a2fd (diff)
downloadandroid_bionic-1e980b6bc8315d00a07312b25486531247abd98c.tar.gz
android_bionic-1e980b6bc8315d00a07312b25486531247abd98c.tar.bz2
android_bionic-1e980b6bc8315d00a07312b25486531247abd98c.zip
Fix the duplication in the debugging code.
We had two copies of the backtrace code, and two copies of the libcorkscrew /proc/pid/maps code. This patch gets us down to one. We also had hacks so we could log in the malloc debugging code. This patch pulls the non-allocating "printf" code out of the dynamic linker so everyone can share. This patch also makes the leak diagnostics easier to read, and makes it possible to paste them directly into the 'stack' tool (by using relative PCs). This patch also fixes the stdio standard stream leak that was causing a leak warning every time tf_daemon ran. Bug: 7291287 Change-Id: I66e4083ac2c5606c8d2737cb45c8ac8a32c7cfe8
Diffstat (limited to 'libc/bionic/logd_write.c')
-rw-r--r--libc/bionic/logd_write.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libc/bionic/logd_write.c b/libc/bionic/logd_write.c
index 71a6f8e80..11c0e68b6 100644
--- a/libc/bionic/logd_write.c
+++ b/libc/bionic/logd_write.c
@@ -250,9 +250,7 @@ void __libc_android_log_event_uid(int32_t tag)
__LIBC_HIDDEN__
void __fortify_chk_fail(const char *msg, uint32_t tag) {
- __libc_android_log_print(ANDROID_LOG_FATAL, "libc",
- "FORTIFY_SOURCE: %s. Calling abort().\n",
- msg);
+ __libc_format_log(ANDROID_LOG_FATAL, "libc", "FORTIFY_SOURCE: %s. Calling abort().\n", msg);
if (tag != 0) {
__libc_android_log_event_uid(tag);
}