summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Hsieh2012-02-27 18:48:18 -0600
committerAndrew Hsieh2012-02-29 19:00:46 -0600
commitd2c8f52189f8c2a13b88a107c6495f9d83196d2d (patch)
tree2175cb5d16e0e2bc9970ae336f8be94a33c8bb09 /liblog/fake_log_device.c
parentc958a7f4988f3dd98135b23619cdf55ec55bd1f6 (diff)
downloadplatform-system-core-d2c8f52189f8c2a13b88a107c6495f9d83196d2d.tar.gz
platform-system-core-d2c8f52189f8c2a13b88a107c6495f9d83196d2d.tar.xz
platform-system-core-d2c8f52189f8c2a13b88a107c6495f9d83196d2d.zip
Fixed two 64-bit porting issues; Make pid/tid type consistent
1. In printf, use "%zu" for variable of type size_t 2. Print tid in %5d 3. Make type of pid/tid in AndroidLogEntry and logger_entry consistent Change-Id: I3e3d9536ee58823f349a4734ae093d30eabe1bfe
Diffstat (limited to 'liblog/fake_log_device.c')
-rw-r--r--liblog/fake_log_device.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/liblog/fake_log_device.c b/liblog/fake_log_device.c
index f8b725412..df4329921 100644
--- a/liblog/fake_log_device.c
+++ b/liblog/fake_log_device.c
@@ -398,7 +398,7 @@ static void showLog(LogState *state,
398 break; 398 break;
399 case FORMAT_THREAD: 399 case FORMAT_THREAD:
400 prefixLen = snprintf(prefixBuf, sizeof(prefixBuf), 400 prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
401 "%c(%5d:%p) ", priChar, pid, (void*)tid); 401 "%c(%5d:%5d) ", priChar, pid, tid);
402 strcpy(suffixBuf, "\n"); suffixLen = 1; 402 strcpy(suffixBuf, "\n"); suffixLen = 1;
403 break; 403 break;
404 case FORMAT_RAW: 404 case FORMAT_RAW:
@@ -417,8 +417,8 @@ static void showLog(LogState *state,
417 break; 417 break;
418 case FORMAT_LONG: 418 case FORMAT_LONG:
419 prefixLen = snprintf(prefixBuf, sizeof(prefixBuf), 419 prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
420 "[ %s %5d:%p %c/%-8s ]\n", 420 "[ %s %5d:%5d %c/%-8s ]\n",
421 timeBuf, pid, (void*)tid, priChar, tag); 421 timeBuf, pid, tid, priChar, tag);
422 strcpy(suffixBuf, "\n\n"); suffixLen = 2; 422 strcpy(suffixBuf, "\n\n"); suffixLen = 2;
423 break; 423 break;
424 default: 424 default: