1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 11:40:18 +02:00
guile/module
Mark H Weaver e7bd20f7d9 Make (ice-9 popen) thread-safe.
Fixes <http://bugs.gnu.org/15683>.
Reported by David Pirotte <david@altosw.be>.

* module/ice-9/popen.scm: Import (ice-9 threads) and (srfi srfi-9).
  (<pipe-info>): New record type.
  (port/pid-table): Mark as deprecated in comment.
  (port/pid-table-mutex): New variable.
  (open-pipe*): Store the pid in the pipe-info record, and store the
  pipe-info as a port property.  Guard the pipe-info instead of the
  port.  Lock 'port/pid-table-mutex' while mutating 'port/pid-table'.
  (fetch-pid): Removed.
  (fetch-pipe-info): New procedure.
  (close-process-quietly): Removed.
  (close-pipe): Use 'fetch-pipe-info' instead of 'fetch-pid'.  Clear
  the pid from the pipe-info.  Improve error messages.
  (reap-pipes): Adapt to the fact that the pipe-info is now guarded
  instead of the port.  Incorporate the 'waitpid' code that was
  previously in 'close-process-quietly', but let the port finalizer
  close the port.  Clear the pid from the pipe-info.
2013-11-23 17:47:39 -05:00
..
ice-9 Make (ice-9 popen) thread-safe. 2013-11-23 17:47:39 -05:00
language Common numeric operations are left-to-right associative. 2013-08-12 20:03:41 -04:00
oop Clarify the copyright status of GOOPS. 2013-01-26 15:41:05 +01:00
rnrs Convert guile exceptions to R6RS conditions in R6RS exception handlers. 2013-11-18 00:35:42 -05:00
scripts Fix a couple of warnings. 2012-01-26 00:37:23 +01:00
srfi Adapt srfi-9.test to error reporting improvements; update copyright dates. 2013-09-12 18:14:54 -04:00
sxml Remove duplicate definitions of call/ec' and let/ec'. 2013-04-06 15:40:19 +02:00
system Consume a peeked EOF at the REPL. 2013-04-08 08:44:02 -04:00
texinfo texinfo plain-text: Use match' for stexi->plain-text'. 2013-03-22 22:09:05 +01:00
web Web: accept "UTC" as the zone offset in date headers. 2013-11-19 03:22:00 -05:00
Makefile.am Add procedures to convert alists into hash tables. 2013-11-18 23:03:38 -05:00
rnrs.scm Add missing R6RS `open-file-input/output-port' procedure 2012-11-12 20:47:57 +01:00
statprof.scm add gcprof 2011-05-05 11:43:12 +02:00
texinfo.scm texinfo: Recognize `@:'. 2013-03-21 18:52:29 +01:00