Browse Source

* runtest.exp: Use 'array exists' for testing array existence

rather than 'info exists'.
dejagnu-1.6
Ben Elliston 11 years ago
parent
commit
c3c0aef7bd
  1. 5
      ChangeLog
  2. 4
      runtest.exp

5
ChangeLog

@ -1,3 +1,8 @@
2016-03-28 Ben Elliston <bje@gnu.org>
* runtest.exp: Use 'array exists' for testing array existence
rather than 'info exists'.
2016-03-28 Ben Elliston <bje@gnu.org>
* runtest.exp: Fixes identified by the Frink static analyser:

4
runtest.exp

@ -1750,7 +1750,7 @@ foreach current_target $target_list {
}
verbose "Top level testsuite dirs are ${test_top_dirs}" 2
set testlist ""
if {[info exists all_runtests]} {
if {[array exists all_runtests]} {
foreach x [array names all_runtests] {
verbose "trying to glob ${srcdir}/${x}" 2
set s [glob -nocomplain ${srcdir}/$x]
@ -1876,7 +1876,7 @@ foreach current_target $target_list {
# Check to see if the range of tests is limited,
# set `runtests' to a list of two elements: the script name
# and any arguments ("" if none).
if {[info exists all_runtests]} {
if {[array exists all_runtests]} {
verbose "searching for $test_name in [array names all_runtests]"
if { 0 > [lsearch [array names all_runtests] [file tail $test_name]]} {
if { 0 > [lsearch [array names all_runtests] $test_name] } {

Loading…
Cancel
Save