run: use 'wait_for_output' for Linux, too

With this patch, the Linux-specific 'run_genode_until' function uses
'wait_for_output' as it gets already used for other run targets.

Fixes #863.
This commit is contained in:
Christian Prochaska 2013-08-30 12:54:07 +02:00 committed by Norman Feske
parent da2c6b62f2
commit 8a2e543b69
1 changed files with 4 additions and 9 deletions

View File

@ -35,18 +35,13 @@ proc run_genode_until {{wait_for_re forever} {timeout_value 0} {running_spawn_id
return
}
global output
set timeout $timeout_value
global spawn_id
set orig_pwd [pwd]
cd [run_dir]
set pid [spawn ./core]
if {$wait_for_re == "forever"} { interact $pid }
expect {
-re $wait_for_re { }
timeout { puts stderr "Error: Test execution timed out"; exit -2 }
}
spawn ./core
wait_for_output $wait_for_re $timeout_value $spawn_id
cd $orig_pwd
set output $expect_out(buffer)
}