RUN-PROGRAM is not multi-thread safe
Bug #1810856 reported by
Ilya Perminov
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
RUN-PROGRAM produces random IO-related errors when it is used concurrently from several threads. 1.4.15 is broken, but 1.4.12 works fine. So, the bug is probably caused by the recent RUN-PROGRAM changes.
Environment: Ubuntu 18.04, Linux 3.13.0-161-generic #211-Ubuntu SMP x86_64.
Changed in sbcl: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Errors:
(#<SB-IMPL::HANDLER INPUT on BOGUS descriptor 5: #<CLOSURE (LAMBDA
(
SB-IMPL: :FD)
:IN
SB- IMPL::SETUP- SERVE-EVENT- PIPE) {10049FD83B}>>) has a bad file descriptor.
[Condition of type SIMPLE-ERROR]
Restarts:
0: [REMOVE-THEM] Remove bogus handlers.
1: [RETRY-THEM] Retry bogus handlers.
2: [CONTINUE] Go on, leaving handlers marked as bogus.
3: [ABORT] abort thread (#<THREAD RUNNING {10049E2D13}>)
Backtrace: :HANDLER- DESCRIPTORS- ERROR (#<SB-IMPL::HANDLER INPUT on BOGUS descriptor 5: #<CLOSURE (LAMBDA (SB-IMPL::FD) :IN SB-IMPL: :SETUP- SERVE-EVENT- PIPE) {10049FD83B}>>)) :SUB-SERVE- EVENT 10 0 NIL) SERVE-ALL- EVENTS 10)
0: (SB-IMPL:
1: (SB-IMPL:
2: (SB-SYS:
3: (PROCESS-WAIT #<SB-IMPL::PROCESS :EXITED 0> NIL)
Couldn't write to #<SB-SYS:FD-STREAM for "descriptor 7" {10040833B3}>: SIMPLE- STREAM- ERROR]
Bad file descriptor
[Condition of type SB-INT:
Restarts:
0: [ABORT] abort thread (#<THREAD RUNNING {100406CC03}>)
Backtrace: :FLUSH- OUTPUT- BUFFER #<SB-SYS:FD-STREAM for "descriptor 7" {10040833B3}>) :FINISH- FD-STREAM- OUTPUT #<SB-SYS:FD-STREAM for "descriptor 7" {10040833B3}>) :FD-STREAM- MISC-ROUTINE #<SB-SYS:FD-STREAM for "descriptor 7" {10040833B3}> :CLOSE NIL #<unused argument>) ANSI-STREAM) ) #<SB-SYS:FD-STREAM for "descriptor 7" {10040833B3}> :ABORT NIL) [fast-method]
0: (SB-IMPL:
1: (SB-IMPL:
2: (SB-IMPL:
3: ((:METHOD CLOSE (SB-KERNEL: