Mon, 23 Dec 2019 21:31:48 +0200
bind, close
src/Visualise.jl | file | annotate | diff | comparison | revisions |
--- a/src/Visualise.jl Mon Dec 23 21:30:38 2019 +0200 +++ b/src/Visualise.jl Mon Dec 23 21:31:48 2019 +0200 @@ -191,7 +191,8 @@ if visualise rc = Channel(1) visproc = Threads.@spawn bg_visualise(rc) - vis =rc + bind(rc, visproc) + vis = rc else vis = false visproc = nothing @@ -207,6 +208,7 @@ if isa(st.vis, Channel) # Tell subprocess to finish, and wait put!(st.vis, nothing) + close(st.vis) wait(st.visproc) end end