diff options
author | Ross Burton <ross.burton@arm.com> | 2021-07-12 14:50:13 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-07-13 14:24:48 +0100 |
commit | bcd792270676beeac73f3900346184dec24d00a1 (patch) | |
tree | 0750d6a633efa43f999bde7db8efd4f11eefe983 /meta/recipes-devtools/tcltk | |
parent | 2ee179c78d8904da5c1a28855e3bc4a01a4c3db6 (diff) | |
download | openembedded-core-contrib-bcd792270676beeac73f3900346184dec24d00a1.tar.gz |
tcl: fix race in interp.test
There's a timeout race in interp which is exposed when running under load.
Signed-off-by: Ross Burton <ross.burton@arm.com>
Diffstat (limited to 'meta/recipes-devtools/tcltk')
-rw-r--r-- | meta/recipes-devtools/tcltk/tcl/interp.patch | 32 | ||||
-rw-r--r-- | meta/recipes-devtools/tcltk/tcl_8.6.11.bb | 1 |
2 files changed, 33 insertions, 0 deletions
diff --git a/meta/recipes-devtools/tcltk/tcl/interp.patch b/meta/recipes-devtools/tcltk/tcl/interp.patch new file mode 100644 index 0000000000..95d6318f64 --- /dev/null +++ b/meta/recipes-devtools/tcltk/tcl/interp.patch @@ -0,0 +1,32 @@ +The interp-36.7 patch has race conditions and is missing cleanup. This patch by +a Tcl maintainer should improve matters. + +Upstream-Status: Pending +Signed-off-by: Ross Burton <ross.burton@arm.com> + +diff --git a/tests/interp.test b/tests/interp.test +index d7424847f..fc90990f3 100644 +--- a/tests/interp.test ++++ b/tests/interp.test +@@ -3595,17 +3595,18 @@ test interp-36.7 {ChildBgerror sets error handler of child [1999035]} -setup { + variable result + set result [lindex $args 0] + } ++ set tout [after 5000 {set result timeout}] + } -body { + child eval { + variable done {} + after 0 error foo +- after 10 [list ::set [namespace which -variable done] {}] +- vwait [namespace which -variable done] + } ++ vwait result + set result + } -cleanup { ++ after cancel $tout + variable result {} +- unset -nocomplain result ++ unset -nocomplain result tout + interp delete child + } -result foo + diff --git a/meta/recipes-devtools/tcltk/tcl_8.6.11.bb b/meta/recipes-devtools/tcltk/tcl_8.6.11.bb index 0d7c2e4ac3..57a86e4c64 100644 --- a/meta/recipes-devtools/tcltk/tcl_8.6.11.bb +++ b/meta/recipes-devtools/tcltk/tcl_8.6.11.bb @@ -22,6 +22,7 @@ SRC_URI = "${BASE_SRC_URI} \ file://fix_issue_with_old_distro_glibc.patch \ file://tcl-remove-hardcoded-install-path.patch \ file://alter-includedir.patch \ + file://interp.patch \ file://run-ptest \ " SRC_URI[sha256sum] = "cfb49aab82bd179651e23eeeb69606f51b0ddc575ca55c3d35e2457469024cfa" |