Prevent test code crash due to no log data
Former-commit-id: 0a56a73bd98d4e692ae77683fdb9dd644ecfc2eb
This commit is contained in:
parent
40a5f86dad
commit
1554161bdc
@ -39,6 +39,7 @@ proc show_cluster_status {} {
|
|||||||
# all the lists are empty.
|
# all the lists are empty.
|
||||||
#
|
#
|
||||||
# regexp {^[0-9]+:[A-Z] [0-9]+ [A-z]+ [0-9]+ ([0-9:.]+) .*} $l - logdate
|
# regexp {^[0-9]+:[A-Z] [0-9]+ [A-z]+ [0-9]+ ([0-9:.]+) .*} $l - logdate
|
||||||
|
catch {
|
||||||
while 1 {
|
while 1 {
|
||||||
# Find the log with smallest time.
|
# Find the log with smallest time.
|
||||||
set empty 0
|
set empty 0
|
||||||
@ -67,6 +68,7 @@ proc show_cluster_status {} {
|
|||||||
puts "\[$best port $R_port($best)\] [lindex $log($best) 0]"
|
puts "\[$best port $R_port($best)\] [lindex $log($best) 0]"
|
||||||
set log($best) [lrange $log($best) 1 end]
|
set log($best) [lrange $log($best) 1 end]
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user