The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

Changes for version 0.20

  • Fixed rare thread start race condition where parent thread would block indefinately if child thread were to spawn, complete, and exit before the parent could obtain the TID associated with the child thread.
  • Corrected a few cases in server timedwait handling, cond_broadcast, and cond_signal where a lock could be prematurely transferred to another thread if the main thread (tid 0) were holding the lock at the time the event expired.
  • Modified cond_timedwait to support fractional seconds (if Time::HiRes is loaded before forks).
  • Minor changes to forks.xs for backwards compatibility with gcc 2.96.
  • Minor cleanup in (forks.xs) bless reference handling.
  • When using INET sockets, peer address is validated against the loopback address (IPv4 127.0.0.1) before accepting the connection; otherwise, socket is immediately closed and a warning is emitted.
  • Added THREADS_IP_MASK env param to allow override of default IP mask filter.
  • Misc cleanup of internal server environment variable handling.
  • Moved some server code into separate subroutines.

Modules

drop-in replacement for Perl threads using fork()
drop-in replacement for Perl threads::shared with forks()
default class for tie-ing arrays to threads with forks
default class for tie-ing handles to threads with forks
default class for tie-ing hashes to threads with forks
default class for tie-ing scalars to threads with forks

Provides

in lib/forks.pm
in lib/forks/shared.pm