| Index: tools/testing/dart/test_runner.dart
|
| diff --git a/tools/testing/dart/test_runner.dart b/tools/testing/dart/test_runner.dart
|
| index 132d0c6d7f3d6ffc5d84b467a290b11ff8dcbc9d..f8570c0200990185da7b3f31b382d74733f81544 100644
|
| --- a/tools/testing/dart/test_runner.dart
|
| +++ b/tools/testing/dart/test_runner.dart
|
| @@ -1854,8 +1854,24 @@ class RunningProcess {
|
| void timeoutHandler() {
|
| timedOut = true;
|
| if (process != null) {
|
| - if (!process.kill()) {
|
| - DebugLogger.error("Unable to kill ${process.pid}");
|
| + if (io.Platform.isLinux) {
|
| + // Try to print stack traces of the timed out process.
|
| + io.Process.run('eu-stack', ['-p ${process.pid}'])
|
| + .then((result) {
|
| + io.stdout.write(result.stdout);
|
| + io.stderr.write(result.stderr);
|
| + })
|
| + .catchError(
|
| + (error) => print("Error when printing stack trace: $error"))
|
| + .whenComplete(() {
|
| + if (!process.kill()) {
|
| + DebugLogger.error("Unable to kill ${process.pid}");
|
| + }
|
| + });
|
| + } else {
|
| + if (!process.kill()) {
|
| + DebugLogger.error("Unable to kill ${process.pid}");
|
| + }
|
| }
|
| }
|
| }
|
|
|