summaryrefslogtreecommitdiffstats
path: root/liblog/tests
diff options
context:
space:
mode:
Diffstat (limited to 'liblog/tests')
-rw-r--r--liblog/tests/liblog_benchmark.cpp2
-rw-r--r--liblog/tests/liblog_test.cpp2
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;
}