Help for this page

Select Code to Download


  1. or download this
    for my $key ( @locking keys ) {
        lock( $h{ $_ } );
    ##  Presumably code goes here
        cond_signal( $h{ $_ } );
    }
    
  2. or download this
    #!/usr/local/perl_ithreads/bin/perl
    use strict;
    ...
    
        cond_signal( $guard ); ## unlock the guard (atomic)
    }