diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/qemuimage-testlib | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/scripts/qemuimage-testlib b/scripts/qemuimage-testlib index 79882d9ea7..2c38b9413b 100644 --- a/scripts/qemuimage-testlib +++ b/scripts/qemuimage-testlib | |||
@@ -204,8 +204,8 @@ Test_Kill_Qemu() | |||
204 | # function to check if there is any qemu process | 204 | # function to check if there is any qemu process |
205 | Test_Check_Qemu_UP() | 205 | Test_Check_Qemu_UP() |
206 | { | 206 | { |
207 | local count=`ps -ef | grep -c qemu` | 207 | local count=`ps -eo command | cut -d " " -f 1 | grep -c \(^qemu\|.*/qemu\)` |
208 | if [ ${count} -lt 2 ]; then | 208 | if [ ${count} -lt 1 ]; then |
209 | Test_Info "There is no Qemu process" | 209 | Test_Info "There is no Qemu process" |
210 | return 1 | 210 | return 1 |
211 | else | 211 | else |
@@ -402,9 +402,7 @@ Test_Create_Qemu() | |||
402 | # Get the pid of the xterm processor, which will be used in Test_Kill_Qemu | 402 | # Get the pid of the xterm processor, which will be used in Test_Kill_Qemu |
403 | PID=$! | 403 | PID=$! |
404 | 404 | ||
405 | sleep 5 | 405 | while [ ${up_time} -lt 10 ] |
406 | |||
407 | while [ ${up_time} -lt ${timeout} ] | ||
408 | do | 406 | do |
409 | Test_Check_Qemu_UP | 407 | Test_Check_Qemu_UP |
410 | if [ $? -ne 0 ]; then | 408 | if [ $? -ne 0 ]; then |