diff options
Diffstat (limited to 'lib/MCE/Channel/MutexFast.pm')
-rw-r--r-- | lib/MCE/Channel/MutexFast.pm | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/lib/MCE/Channel/MutexFast.pm b/lib/MCE/Channel/MutexFast.pm index a1007ac..b1cc56b 100644 --- a/lib/MCE/Channel/MutexFast.pm +++ b/lib/MCE/Channel/MutexFast.pm @@ -11,7 +11,7 @@ use warnings; no warnings qw( uninitialized once ); -our $VERSION = '1.888'; +our $VERSION = '1.889'; use base 'MCE::Channel'; use MCE::Mutex (); @@ -220,17 +220,9 @@ sub send2 { my $data = ''.shift; local $\ = undef if (defined $\); - local $MCE::Signal::SIG; - - { - local $MCE::Signal::IPC = 1; - ( my $c_mutex = $self->{c_mutex} )->lock2; - + $self->{c_mutex}->synchronize2( sub { print { $self->{c_sock} } pack('i', length $data), $data; - $c_mutex->unlock2; - } - - CORE::kill($MCE::Signal::SIG, $$) if $MCE::Signal::SIG; + }); return 1; } @@ -308,7 +300,7 @@ MCE::Channel::MutexFast - Fast channel for producer(s) and many consumers =head1 VERSION -This document describes MCE::Channel::MutexFast version 1.888 +This document describes MCE::Channel::MutexFast version 1.889 =head1 DESCRIPTION |