Crash when run-program writes to a file stream
If I run
(with-open-file (output "output-file" :direction :output :if-exists :supersede)
(mk-ext:run-program "echo" '("foo") :input nil :wait t :output output))
Three values are returned but I also get
Debugger called in: #<thread "from-subprocess-worker (pid: 3101)" active detached (3102) 0x7f32d7fff700 7f32ec4be000>.
#<a SI:OS-STREAM-ERROR 139856689642976>:
Stream error: OS level error on stream #<closed output stream (C stdio) "output-file">.
Read or write operation signaled an error.
OS Explanation: (errno == 9) Bad file descriptor
And then once I quit
:
*** Error in `mkcl': corrupted double-linked list: 0x0000000002b7b580 ***