diff options
author | Mark Salyzyn <salyzyn@google.com> | 2014-03-05 07:41:49 -0800 |
---|---|---|
committer | Mark Salyzyn <salyzyn@google.com> | 2014-03-05 16:12:28 -0800 |
commit | 7e2f83c0bcc3ad8a2840a48be14d302ed79d671c (patch) | |
tree | e2d2ed4a9a9e218e046cb0796607cca8fc5ed97f /liblog/tests | |
parent | 51ebffd8a5536af09b60950bf7cf6f020c962f8a (diff) | |
download | system_core-7e2f83c0bcc3ad8a2840a48be14d302ed79d671c.zip system_core-7e2f83c0bcc3ad8a2840a48be14d302ed79d671c.tar.gz system_core-7e2f83c0bcc3ad8a2840a48be14d302ed79d671c.tar.bz2 |
logd: liblog: 64-bit issues
- structure packing
- move towards log_time from struct timespec
- extend log_time to cover differences between
log_time and struct timespec
Change-Id: I106ed0b609917306d170044054b5b32645f2a295
Diffstat (limited to 'liblog/tests')
-rw-r--r-- | liblog/tests/liblog_benchmark.cpp | 2 | ||||
-rw-r--r-- | liblog/tests/liblog_test.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/liblog/tests/liblog_benchmark.cpp b/liblog/tests/liblog_benchmark.cpp index 19406fb..39fe2ad 100644 --- a/liblog/tests/liblog_benchmark.cpp +++ b/liblog/tests/liblog_benchmark.cpp @@ -143,7 +143,7 @@ static void BM_log_latency(int iters) { for (int j = 0, i = 0; i < iters && j < 10*iters; ++i, ++j) { log_time ts; LOG_FAILURE_RETRY(( - clock_gettime(CLOCK_REALTIME, &ts), + ts = log_time(CLOCK_REALTIME), android_btWriteLog(0, EVENT_TYPE_LONG, &ts, sizeof(ts)))); for (;;) { diff --git a/liblog/tests/liblog_test.cpp b/liblog/tests/liblog_test.cpp index d71d97a..ffb7fd1 100644 --- a/liblog/tests/liblog_test.cpp +++ b/liblog/tests/liblog_test.cpp @@ -171,7 +171,7 @@ static void caught_blocking(int signum) ++signaled; if ((signal_time.tv_sec == 0) && (signal_time.tv_nsec == 0)) { - clock_gettime(CLOCK_MONOTONIC, &signal_time); + signal_time = log_time(CLOCK_MONOTONIC); signal_time.tv_sec += 2; } |