This is the mail archive of the
mailing list for the GDB project.
Re: [patch] print-threads.exp: Extend timeout for slower tests.
> >> +# Record the old timeout, we need to extend it for slower tests.
> >> +set oldtimeout $timeout
> > You can use global $gdb_test_timeout nowadays.
> Thanks, I didn't know about gdb_test_timeout.
> Still, I like the patch as is, one less global the code has to care about.
Same here. I don't think that this variable is meant to be changed
by testcases when you just want to change it for a few tests.
Otherwise, you run the risk of affecting all the other testcases,
which set the timeout to $gdb_test_timeout at the start of every
testcase (this was done to prevent a change of timeout duration
from affecting subsequent testcases). See gdb_init:
# Reset the timeout value to the default. This way, any testcase
# that changes the timeout value without resetting it cannot affect
# the timeout used in subsequent testcases.
set timeout $gdb_test_timeout