summaryrefslogtreecommitdiffstats
path: root/cmds
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2015-01-09 15:56:21 -0800
committerChristopher Ferris <cferris@google.com>2015-01-09 16:42:56 -0800
commit67c5a8af9ed128d8bb56d4723303aef6f0a4500f (patch)
tree2c0bec8453a658be482651f4bd540f95b1c937ed /cmds
parent96e4409e8c38b1d79285eca9886d44ff850b5748 (diff)
downloadframeworks_native-67c5a8af9ed128d8bb56d4723303aef6f0a4500f.zip
frameworks_native-67c5a8af9ed128d8bb56d4723303aef6f0a4500f.tar.gz
frameworks_native-67c5a8af9ed128d8bb56d4723303aef6f0a4500f.tar.bz2
Fix message when a command times out.
The previous version printed out the nanoseconds elapsed, not seconds. Change-Id: I10f6d7bf7b7a4647658313ed83781fda6fd744a5
Diffstat (limited to 'cmds')
-rw-r--r--cmds/dumpstate/utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmds/dumpstate/utils.c b/cmds/dumpstate/utils.c
index e3042eb..81cdd12 100644
--- a/cmds/dumpstate/utils.c
+++ b/cmds/dumpstate/utils.c
@@ -360,7 +360,7 @@ int run_command(const char *title, int timeout_seconds, const char *command, ...
}
if (timeout_seconds && elapsed / NANOS_PER_SEC > timeout_seconds) {
- printf("*** %s: Timed out after %ds (killing pid %d)\n", command, (int) elapsed, pid);
+ printf("*** %s: Timed out after %.3fs (killing pid %d)\n", command, (float) elapsed / NANOS_PER_SEC, pid);
kill(pid, SIGTERM);
return -1;
}