Result:
found more than 757 distributions - search limited to the first 2001 files matching your query ( run in 1.232 )


ClearCase-Wrapper-MGi

 view release on metacpan or  search on metacpan

MGi.pm  view on Meta::CPAN

	push @args, '-obs' if $1;
      } else {
	push @cmt, $_;
      }
    }
    unshift @cmt, "Relocked to mkhlink. Locked on $date by $user";
    push @args, '-c', join('\n',@cmt), $obj;
  }
  return @args;
}

MGi.pm  view on Meta::CPAN

Comments go to the type being archived.

The implementation is largely shared with I<mkbrtype>.

For label types, the newly created type is hidden away (with a suffix
of I<_0>) and locked. It is being restored the next time C<mklbtype -fam>
is given for the same name.

=item B<-glo/bal>

Support for global family types is preliminary.

MGi.pm  view on Meta::CPAN

  use warnings;
  my $type = shift;
  return sub {
    my ($mkt, $arg) = @_;
    $arg = "$type:$arg" unless $arg =~ /^$type:/;
    # Maybe need to check that non locked?
    return ClearCase::Argv->des('-s', $arg)->stdout(0)->system? 0 : 1;
  };
}
sub mklbtype {
  use strict;

MGi.pm  view on Meta::CPAN

New B<-allow> and B<-deny> flags. These work like I<-nuser> but operate
incrementally on an existing I<-nuser> list rather than completely
replacing it. When B<-allow> or B<-deny> are used, I<-replace> is
implied.

When B<-iflocked> is used, no lock will be created where one didn't
previously exist; the I<-nusers> list will only be modified for
existing locks.

In case of a family type, lock also the equivalent incremental type.

MGi.pm  view on Meta::CPAN


sub lock {
  use warnings;
  use strict;
  my (%opt, $nusers);
  GetOptions(\%opt, qw(allow=s deny=s iflocked));
  GetOptions('nusers=s' => \$nusers);
  my $lock = ClearCase::Argv->new(@ARGV);
  $lock->parse(qw(c|cfile=s cquery|cqeach nc pname=s obsolete replace));
  die Msg('E', "cannot specify -nusers along with -allow or -deny")
    if %opt and $nusers;

MGi.pm  view on Meta::CPAN

      }
    }
    $lock->opts($lock->opts, '-nusers', join(',', sort keys %nusers))
      if %nusers;
  } elsif (($nusers or $opt{allow}) and
	     (!$currlock or $opt{iflocked} or $lock->flag('replace'))) {
    $lock->opts($lock->opts, '-nusers', ($nusers or $opt{allow}));
  }
  if ($currlock and !$lock->flag('replace')) {
    if ($opt{allow} or $opt{deny}) {
      $lock->opts($lock->opts, '-replace')
    } else {
      die Msg('E', 'Object is already locked.');
    }
  }
  my @args = $lock->args;
  $CT = ClearCase::Argv->new({autochomp=>1});
  my (@lbt, @oth, %vob);

MGi.pm  view on Meta::CPAN

	}
      } else {
	print @out;
      }
    } else {
      warn Msg('E', 'Object is not locked.');
      warn Msg('E', "Unable to unlock label type \"$lt\".");
      $rc = 1;
    }
  }
  for (@args) {

MGi.pm  view on Meta::CPAN

=over

=item -fam: remove all types in the family, as well as the I<RmLBTYPE>
attribute type. This is a rare and destructive situation, unless the
equivalent type is I<LBTYPE_1.00> (the family was just created).
The types actually affected ought of course to be unlocked.

=item -inc: remove the current increment, and move back the family
type onto the previous one. Note: I<RmLBTYPE> attributes ... may be
left behind (for now...)

MGi.pm  view on Meta::CPAN

      $dst =~ s/@\Q$vob\E$/\@$_/;
      _Wrap('cptype', $lbl, $dst); #Fails if the type existed in one vob
    }
  } else {
    if ($CT->des([qw(-s -ahl), $EQHL], $lbl)->qx) {
      die Msg('E', 'The baseline is not locked: conflicting rollout pending?')
	if $ClearCase::Wrapper::MGi::lockbl and !$CT->lslock(['-s'], $lbl)->qx;
      _Wrap(qw(mklbtype -inc), @cmt, $lbl) and die "\n";
    } else {
      die Msg('E', 'The baseline type must be a family type');
    }

MGi.pm  view on Meta::CPAN

	}
      }
      print STDERR "$e\n";
    } else {
      my @opts = ($lock and $CT->lslock(['-s'], $lbt)->qx)?
	('-fmt', '%n (%[locked]p)\n') : @dopts;
      $CT->des([@opts], $lbt)->system;
    }
    return 1;			#continue
  };
  $lst->pipecb($cb);

MGi.pm  view on Meta::CPAN

    my $lbtype = "lbtype:$opt{label}\@$dvob";
    $sync->lblver($opt{label}) if $opt{vreuse} && $ct->des(['-s'], $lbtype)->qx;
    my ($inclb) = grep s/-> (lbtype:.*)$/$1/,
      $ct->des([qw(-s -ahl EqInc)], $lbtype)->qx;
    if ($inclb) {
      die "$prog: Error: incremental label types must be unlocked\n"
	if $ct->lslock(['-s'], $lbtype, $inclb)->qx;
      $inclb =~ s/^lbtype:(.*)@.*$/$1/;
      $sync->inclb($inclb);
    }
  }

 view all matches for this distribution


Clone-Closure

 view release on metacpan or  search on metacpan

t/04hv.t  view on Meta::CPAN

        my %hash = qw/a b c d/;
        lock_keys(%hash, qw/a c e/);
        my $hv   = clone \%hash;

        is  join(':', sort keys %$hv),
                                    'a:c',  'locked HV retains keys';
        ok  !exists( $hv->{e} ),            'exists still works';
        ok  eval { $hv->{e} = 1 },          'permitted key';
        ok  !eval { $hv->{f} = 1 },         'forbidden key';
        
        delete $hv->{a};
        ok  !exists( $hv->{a} ),            'delete still works';

        unlock_keys(%$hv);
        ok  eval { $hv->{f} = 1 },          'can be unlocked';
        ok  exists( $hv->{f} ),             '...and insert now works';
        ok  !eval { $hash{f} = 1 },         '...but parent is still locked';
    }

    {
        BEGIN { $skip += 5 }

        my %hash = qw/a b c d/;
        lock_keys(%hash);
        lock_value(%hash, 'a');
        my $hv   = clone \%hash;

        is  $hv->{a},       'b',            'locked value is retained';
        ok  !eval { $hv->{a} = 1 },         '...but cannot be changed';

        unlock_value(%$hv, 'a');
        ok  eval { $hv->{a} = 1 },          'can be unlocked';
        is  $hv->{a},       1,              '...and can now be changed';
        ok  !eval { $hash{a} = 1 },         '...but parent is still locked';
    }

    BEGIN { $tests += $skip }
}

 view all matches for this distribution


Clone

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

get_av|5.006000|5.003007|p
getc|5.003007||Viu
get_c_backtrace|5.021001||Vi
get_c_backtrace_dump|5.021001||V
get_context|5.006000|5.006000|nu
getc_unlocked|5.003007||Viu
get_cv|5.006000|5.003007|p
get_cvn_flags|5.009005|5.003007|p
get_cvs|5.011000|5.003007|p
getcwd_sv|5.007002|5.007002|
get_db_sub|||iu

ppport.h  view on Meta::CPAN

PERL_MALLOC_WRAP|5.009002|5.009002|Vn
PerlMem_calloc|5.006000||Viu
PerlMem_free|5.005000||Viu
PerlMem_free_lock|5.006000||Viu
PerlMem_get_lock|5.006000||Viu
PerlMem_is_locked|5.006000||Viu
PerlMem_malloc|5.005000||Viu
PERL_MEMORY_DEBUG_HEADER_SIZE|5.019009||Viu
PerlMemParse_calloc|5.006000||Viu
PerlMemParse_free|5.006000||Viu
PerlMemParse_free_lock|5.006000||Viu
PerlMemParse_get_lock|5.006000||Viu
PerlMemParse_is_locked|5.006000||Viu
PerlMemParse_malloc|5.006000||Viu
PerlMemParse_realloc|5.006000||Viu
PerlMem_realloc|5.005000||Viu
PerlMemShared_calloc|5.006000||Viu
PerlMemShared_free|5.006000||Viu
PerlMemShared_free_lock|5.006000||Viu
PerlMemShared_get_lock|5.006000||Viu
PerlMemShared_is_locked|5.006000||Viu
PerlMemShared_malloc|5.006000||Viu
PerlMemShared_realloc|5.006000||Viu
PERL_MG_UFUNC|5.007001||Viu
Perl_modf|5.006000|5.006000|n
PERL_MULTICONCAT_HEADER_SIZE|5.027006||Viu

ppport.h  view on Meta::CPAN

putc|5.003007||Viu
put_charclass_bitmap_innards|5.021004||Viu
put_charclass_bitmap_innards_common|5.023008||Viu
put_charclass_bitmap_innards_invlist|5.023008||Viu
put_code_point|5.021004||Viu
putc_unlocked|5.003007||Viu
putenv|5.005000||Viu
put_range|5.019009||Viu
putw|5.003007||Viu
pv_display|5.006000|5.003007|p
pv_escape|5.009004|5.003007|p

 view all matches for this distribution


CloudCron

 view release on metacpan or  search on metacpan

t/crontab  view on Meta::CPAN

0 23 * * * bash -c /opt/deploy/code/portal/script/purge_sessions.pl

# Create tickets for recurring tasks
0 7 * * *  bash -c /opt/deploy/code/portal/script/create_recurring_tasks_tickets.pl 2>&1 | mutt -s 'Portal Recurring Tasks Ticket Creation' -- oriol.soriano@capside.com
#
# Check blocked recurring tasks
10 7 * * 1 bash -c /opt/deploy/code/portal/script/recurringtasks_check_blocked.pl
#
# RT Tickets not existing @ Portal daily verification
0 8 * * *  bash -c /opt/deploy/code/portal/init/report_rt_tickets_without_tmetadata.pl -v 2>&1 | mutt -s 'RT Tickets without ticket_metadata' -- oriol.soriano@capside.com

# DWH hourly ETLs

 view all matches for this distribution


Clownfish

 view release on metacpan or  search on metacpan

cfcore/Clownfish/Util/Atomic.c  view on Meta::CPAN

#include <windows.h>

bool
cfish_Atomic_wrapped_cas_ptr(void *volatile *target, void *old_value,
                            void *new_value) {
    return InterlockedCompareExchangePointer(target, new_value, old_value)
           == old_value;
}

/************************** Fall back to ptheads ***************************/
#elif defined(CHY_HAS_PTHREAD_H)

 view all matches for this distribution


Code-TidyAll

 view release on metacpan or  search on metacpan

lib/Code/TidyAll/SVN/Precommit.pm  view on Meta::CPAN


    % svn commit -m "fixups" CHI.pm CHI/Driver.pm
    Sending        CHI/Driver.pm
    Sending        CHI.pm
    Transmitting file data ..svn: Commit failed (details follow):
    svn: Commit blocked by pre-commit hook (exit code 255) with output:
    2 files did not pass tidyall check
    lib/CHI.pm: *** 'PerlTidy': needs tidying
    lib/CHI/Driver.pm: *** 'PerlCritic': Code before strictures are enabled
      at /tmp/Code-TidyAll-0e6K/Driver.pm line 2
      [TestingAndDebugging::RequireUseStrict]

 view all matches for this distribution


CodeBase

 view release on metacpan or  search on metacpan

CodeBase.pm  view on Meta::CPAN



=item flush [TRIES]

Flushes to file any outstanding changes (made by C<set_field()>.
Records need to be locked while changes are written.  C<TRIES> is the
number of attempts that should be made to aquire the lock.  Subsequent
attempts are made with a one second interval.


=item pack COMPRESS-MEMO-FLAG

 view all matches for this distribution


CodeManager

 view release on metacpan or  search on metacpan

lib/Prima/CodeManager/Edit.pm  view on Meta::CPAN

	$self-> notify(q(Change)) if $self-> {notifyChangeLock} == 0 && $lock < 0;
}

#-------------------------------------------------------------------------------

sub change_locked
{
	my $self = $_[0];
	return $self-> {notifyChangeLock} != 0;
}

 view all matches for this distribution


Cog

 view release on metacpan or  search on metacpan

share/js/jquery-1.11.3.js  view on Meta::CPAN

				if ( !memory ) {
					self.disable();
				}
				return this;
			},
			// Is it locked?
			locked: function() {
				return !stack;
			},
			// Call all callbacks with the given context and arguments
			fireWith: function( context, args ) {
				if ( list && ( !fired || stack ) ) {

 view all matches for this distribution


Compress-BGZF

 view release on metacpan or  search on metacpan

lib/Compress/BGZF.pm  view on Meta::CPAN


__END__

=head1 NAME

Compress::BGZF - Read/write blocked GZIP (BGZF) files

=head1 SYNOPSIS

    use Compress::BGZF::Writer;
    use Compress::BGZF::Reader;

 view all matches for this distribution


Compress-Bzip2

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

   - fix a couple if dangling else corner cases
     format string errors, and unused variables.
   - [cpan #82576] fix pod formatting errors
   - [cpan #48128] support memBunzip BZh header w/o extra size prefix
     and grow dest buf dynamically. Tests in t/040-memory.t
   - [cpan #40741] fix bzreadline blocked on the broken bz2 files
   - [cpan #84223] fix ignored bzinflateInit args
   - [cpan #48124] Multiple issues with bzinflate
     support PV ref as bzinflate() buffer arg as documented.
     support status checks in chunked bzinflate() calls. t/060-inflate.t
   - [cpan #49618] fix for win32 nmake + gcc

 view all matches for this distribution


Compress-Deflate7

 view release on metacpan or  search on metacpan

7zip/CPP/7zip/Archive/7z/7zDecode.cpp  view on Meta::CPAN

  #ifndef _NO_CRYPTO
  passwordIsDefined = false;
  #endif
  CObjectVector< CMyComPtr<ISequentialInStream> > inStreams;
  
  CLockedInStream lockedInStream;
  lockedInStream.Init(inStream);
  
  for (int j = 0; j < folderInfo.PackStreams.Size(); j++)
  {
    CLockedSequentialInStreamImp *lockedStreamImpSpec = new
        CLockedSequentialInStreamImp;
    CMyComPtr<ISequentialInStream> lockedStreamImp = lockedStreamImpSpec;
    lockedStreamImpSpec->Init(&lockedInStream, startPos);
    startPos += packSizes[j];
    
    CLimitedSequentialInStream *streamSpec = new
        CLimitedSequentialInStream;
    CMyComPtr<ISequentialInStream> inStream = streamSpec;
    streamSpec->SetStream(lockedStreamImp);
    streamSpec->Init(packSizes[j]);
    inStreams.Add(inStream);
  }
  
  int numCoders = folderInfo.Coders.Size();

 view all matches for this distribution


Compress-Raw-Bzip2

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

get_av|5.006000|5.003007|p
getc|5.003007||Viu
get_c_backtrace|5.021001||Vi
get_c_backtrace_dump|5.021001||V
get_context|5.006000|5.006000|nu
getc_unlocked|5.003007||Viu
get_cv|5.006000|5.003007|p
get_cvn_flags|5.009005|5.003007|p
get_cvs|5.011000|5.003007|p
getcwd_sv|5.007002|5.007002|
get_db_sub|||iu

ppport.h  view on Meta::CPAN

PERL_MALLOC_WRAP|5.009002|5.009002|Vn
PerlMem_calloc|5.006000||Viu
PerlMem_free|5.005000||Viu
PerlMem_free_lock|5.006000||Viu
PerlMem_get_lock|5.006000||Viu
PerlMem_is_locked|5.006000||Viu
PerlMem_malloc|5.005000||Viu
PERL_MEMORY_DEBUG_HEADER_SIZE|5.019009||Viu
PerlMemParse_calloc|5.006000||Viu
PerlMemParse_free|5.006000||Viu
PerlMemParse_free_lock|5.006000||Viu
PerlMemParse_get_lock|5.006000||Viu
PerlMemParse_is_locked|5.006000||Viu
PerlMemParse_malloc|5.006000||Viu
PerlMemParse_realloc|5.006000||Viu
PerlMem_realloc|5.005000||Viu
PerlMemShared_calloc|5.006000||Viu
PerlMemShared_free|5.006000||Viu
PerlMemShared_free_lock|5.006000||Viu
PerlMemShared_get_lock|5.006000||Viu
PerlMemShared_is_locked|5.006000||Viu
PerlMemShared_malloc|5.006000||Viu
PerlMemShared_realloc|5.006000||Viu
PERL_MG_UFUNC|5.007001||Viu
Perl_modf|5.006000|5.006000|n
PERL_MULTICONCAT_HEADER_SIZE|5.027006||Viu

ppport.h  view on Meta::CPAN

putc|5.003007||Viu
put_charclass_bitmap_innards|5.021004||Viu
put_charclass_bitmap_innards_common|5.023008||Viu
put_charclass_bitmap_innards_invlist|5.023008||Viu
put_code_point|5.021004||Viu
putc_unlocked|5.003007||Viu
putenv|5.005000||Viu
put_range|5.019009||Viu
putw|5.003007||Viu
pv_display|5.006000|5.003007|p
pv_escape|5.009004|5.003007|p

 view all matches for this distribution


Compress-Raw-Lzma

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

get_av|5.006000|5.003007|p
getc|5.003007||Viu
get_c_backtrace|5.021001||Vi
get_c_backtrace_dump|5.021001||V
get_context|5.006000|5.006000|nu
getc_unlocked|5.003007||Viu
get_cv|5.006000|5.003007|p
get_cvn_flags|5.009005|5.003007|p
get_cvs|5.011000|5.003007|p
getcwd_sv|5.007002|5.007002|
get_db_sub|||iu

ppport.h  view on Meta::CPAN

PERL_MALLOC_WRAP|5.009002|5.009002|Vn
PerlMem_calloc|5.006000||Viu
PerlMem_free|5.005000||Viu
PerlMem_free_lock|5.006000||Viu
PerlMem_get_lock|5.006000||Viu
PerlMem_is_locked|5.006000||Viu
PerlMem_malloc|5.005000||Viu
PERL_MEMORY_DEBUG_HEADER_SIZE|5.019009||Viu
PerlMemParse_calloc|5.006000||Viu
PerlMemParse_free|5.006000||Viu
PerlMemParse_free_lock|5.006000||Viu
PerlMemParse_get_lock|5.006000||Viu
PerlMemParse_is_locked|5.006000||Viu
PerlMemParse_malloc|5.006000||Viu
PerlMemParse_realloc|5.006000||Viu
PerlMem_realloc|5.005000||Viu
PerlMemShared_calloc|5.006000||Viu
PerlMemShared_free|5.006000||Viu
PerlMemShared_free_lock|5.006000||Viu
PerlMemShared_get_lock|5.006000||Viu
PerlMemShared_is_locked|5.006000||Viu
PerlMemShared_malloc|5.006000||Viu
PerlMemShared_realloc|5.006000||Viu
PERL_MG_UFUNC|5.007001||Viu
Perl_modf|5.006000|5.006000|n
PERL_MULTICONCAT_HEADER_SIZE|5.027006||Viu

ppport.h  view on Meta::CPAN

putc|5.003007||Viu
put_charclass_bitmap_innards|5.021004||Viu
put_charclass_bitmap_innards_common|5.023008||Viu
put_charclass_bitmap_innards_invlist|5.023008||Viu
put_code_point|5.021004||Viu
putc_unlocked|5.003007||Viu
putenv|5.005000||Viu
put_range|5.019009||Viu
putw|5.003007||Viu
pv_display|5.006000|5.003007|p
pv_escape|5.009004|5.003007|p

 view all matches for this distribution


Compress-Raw-Zlib

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

get_av|5.006000|5.003007|p
getc|5.003007||Viu
get_c_backtrace|5.021001||Vi
get_c_backtrace_dump|5.021001||V
get_context|5.006000|5.006000|nu
getc_unlocked|5.003007||Viu
get_cv|5.006000|5.003007|p
get_cvn_flags|5.009005|5.003007|p
get_cvs|5.011000|5.003007|p
getcwd_sv|5.007002|5.007002|
get_db_sub|||iu

ppport.h  view on Meta::CPAN

PERL_MALLOC_WRAP|5.009002|5.009002|Vn
PerlMem_calloc|5.006000||Viu
PerlMem_free|5.005000||Viu
PerlMem_free_lock|5.006000||Viu
PerlMem_get_lock|5.006000||Viu
PerlMem_is_locked|5.006000||Viu
PerlMem_malloc|5.005000||Viu
PERL_MEMORY_DEBUG_HEADER_SIZE|5.019009||Viu
PerlMemParse_calloc|5.006000||Viu
PerlMemParse_free|5.006000||Viu
PerlMemParse_free_lock|5.006000||Viu
PerlMemParse_get_lock|5.006000||Viu
PerlMemParse_is_locked|5.006000||Viu
PerlMemParse_malloc|5.006000||Viu
PerlMemParse_realloc|5.006000||Viu
PerlMem_realloc|5.005000||Viu
PerlMemShared_calloc|5.006000||Viu
PerlMemShared_free|5.006000||Viu
PerlMemShared_free_lock|5.006000||Viu
PerlMemShared_get_lock|5.006000||Viu
PerlMemShared_is_locked|5.006000||Viu
PerlMemShared_malloc|5.006000||Viu
PerlMemShared_realloc|5.006000||Viu
PERL_MG_UFUNC|5.007001||Viu
Perl_modf|5.006000|5.006000|n
PERL_MULTICONCAT_HEADER_SIZE|5.027006||Viu

ppport.h  view on Meta::CPAN

putc|5.003007||Viu
put_charclass_bitmap_innards|5.021004||Viu
put_charclass_bitmap_innards_common|5.023008||Viu
put_charclass_bitmap_innards_invlist|5.023008||Viu
put_code_point|5.021004||Viu
putc_unlocked|5.003007||Viu
putenv|5.005000||Viu
put_range|5.019009||Viu
putw|5.003007||Viu
pv_display|5.006000|5.003007|p
pv_escape|5.009004|5.003007|p

 view all matches for this distribution


Compress-Snappy

 view release on metacpan or  search on metacpan

src/csnappy_compress.c  view on Meta::CPAN

 * *** DO NOT CHANGE THE VALUE OF kBlockSize ***

 * New Compression code chops up the input into blocks of at most
 * the following size.  This ensures that back-references in the
 * output never cross kBlockSize block boundaries.  This can be
 * helpful in implementing blocked decompression.  However the
 * decompression code should not rely on this guarantee since older
 * compression code may not obey it.
 */
#define kBlockLog 15
#define kBlockSize (1 << kBlockLog)

 view all matches for this distribution


Compress-Stream-Zstd

 view release on metacpan or  search on metacpan

ext/zstd/programs/fileio.c  view on Meta::CPAN

    ZSTD_frameProgression previous_zfp_correction = { 0, 0, 0, 0, 0, 0 };
    typedef enum { noChange, slower, faster } speedChange_e;
    speedChange_e speedChange = noChange;
    unsigned flushWaiting = 0;
    unsigned inputPresented = 0;
    unsigned inputBlocked = 0;
    unsigned lastJobID = 0;
    UTIL_time_t lastAdaptTime = UTIL_getTime();
    U64 const adaptEveryMicro = REFRESH_RATE;

    UTIL_HumanReadableSize_t const file_hrs = UTIL_makeHumanReadableSize(fileSize);

ext/zstd/programs/fileio.c  view on Meta::CPAN

            CHECK_V(stillToFlush, ZSTD_compressStream2(ress.cctx, &outBuff, &inBuff, directive));
            AIO_ReadPool_consumeBytes(ress.readCtx, inBuff.pos - oldIPos);

            /* count stats */
            inputPresented++;
            if (oldIPos == inBuff.pos) inputBlocked++;  /* input buffer is full and can't take any more : input speed is faster than consumption rate */
            if (!toFlushNow) flushWaiting = 1;

            /* Write compressed stream */
            DISPLAYLEVEL(6, "ZSTD_compress_generic(end:%u) => input pos(%u)<=(%u)size ; output generated %u bytes \n",
                         (unsigned)directive, (unsigned)inBuff.pos, (unsigned)inBuff.size, (unsigned)outBuff.pos);

ext/zstd/programs/fileio.c  view on Meta::CPAN

                    unsigned long long newlyProduced = zfp.produced - previous_zfp_update.produced;
                    unsigned long long newlyFlushed = zfp.flushed - previous_zfp_update.flushed;
                    assert(zfp.produced >= previous_zfp_update.produced);
                    assert(prefs->nbWorkers >= 1);

                    /* test if compression is blocked
                        * either because output is slow and all buffers are full
                        * or because input is slow and no job can start while waiting for at least one buffer to be filled.
                        * note : exclude starting part, since currentJobID > 1 */
                    if ( (zfp.consumed == previous_zfp_update.consumed)   /* no data compressed : no data available, or no more buffer to compress to, OR compression is really slow (compression of a single block is slower than update rate)*/
                        && (zfp.nbActiveWorkers == 0)                       /* confirmed : no compression ongoing */

ext/zstd/programs/fileio.c  view on Meta::CPAN

                if (zfp.currentJobID > lastJobID) {
                    DISPLAYLEVEL(6, "compression level adaptation check \n")

                    /* check input speed */
                    if (zfp.currentJobID > (unsigned)(prefs->nbWorkers+1)) {   /* warm up period, to fill all workers */
                        if (inputBlocked <= 0) {
                            DISPLAYLEVEL(6, "input is never blocked => input is slower than ingestion \n");
                            speedChange = slower;
                        } else if (speedChange == noChange) {
                            unsigned long long newlyIngested = zfp.ingested - previous_zfp_correction.ingested;
                            unsigned long long newlyConsumed = zfp.consumed - previous_zfp_correction.consumed;
                            unsigned long long newlyProduced = zfp.produced - previous_zfp_correction.produced;
                            unsigned long long newlyFlushed  = zfp.flushed  - previous_zfp_correction.flushed;
                            previous_zfp_correction = zfp;
                            assert(inputPresented > 0);
                            DISPLAYLEVEL(6, "input blocked %u/%u(%.2f) - ingested:%u vs %u:consumed - flushed:%u vs %u:produced \n",
                                            inputBlocked, inputPresented, (double)inputBlocked/inputPresented*100,
                                            (unsigned)newlyIngested, (unsigned)newlyConsumed,
                                            (unsigned)newlyFlushed, (unsigned)newlyProduced);
                            if ( (inputBlocked > inputPresented / 8)     /* input is waiting often, because input buffers is full : compression or output too slow */
                                && (newlyFlushed * 33 / 32 > newlyProduced)  /* flush everything that is produced */
                                && (newlyIngested * 33 / 32 > newlyConsumed) /* input speed as fast or faster than compression speed */
                            ) {
                                DISPLAYLEVEL(6, "recommend faster as in(%llu) >= (%llu)comp(%llu) <= out(%llu) \n",
                                                newlyIngested, newlyConsumed, newlyProduced, newlyFlushed);
                                speedChange = faster;
                            }
                        }
                        inputBlocked = 0;
                        inputPresented = 0;
                    }

                    if (speedChange == slower) {
                        DISPLAYLEVEL(6, "slower speed , higher compression \n")

 view all matches for this distribution


Compress-Zstd

 view release on metacpan or  search on metacpan

ext/zstd/programs/fileio.c  view on Meta::CPAN

    ZSTD_frameProgression previous_zfp_correction = { 0, 0, 0, 0, 0, 0 };
    typedef enum { noChange, slower, faster } speedChange_e;
    speedChange_e speedChange = noChange;
    unsigned flushWaiting = 0;
    unsigned inputPresented = 0;
    unsigned inputBlocked = 0;
    unsigned lastJobID = 0;

    DISPLAYLEVEL(6, "compression using zstd format \n");

    /* init */

ext/zstd/programs/fileio.c  view on Meta::CPAN

            size_t const toFlushNow = ZSTD_toFlushNow(ress.cctx);
            CHECK_V(stillToFlush, ZSTD_compressStream2(ress.cctx, &outBuff, &inBuff, directive));

            /* count stats */
            inputPresented++;
            if (oldIPos == inBuff.pos) inputBlocked++;  /* input buffer is full and can't take any more : input speed is faster than consumption rate */
            if (!toFlushNow) flushWaiting = 1;

            /* Write compressed stream */
            DISPLAYLEVEL(6, "ZSTD_compress_generic(end:%u) => input pos(%u)<=(%u)size ; output generated %u bytes \n",
                            (unsigned)directive, (unsigned)inBuff.pos, (unsigned)inBuff.size, (unsigned)outBuff.pos);

ext/zstd/programs/fileio.c  view on Meta::CPAN

                        unsigned long long newlyProduced = zfp.produced - previous_zfp_update.produced;
                        unsigned long long newlyFlushed = zfp.flushed - previous_zfp_update.flushed;
                        assert(zfp.produced >= previous_zfp_update.produced);
                        assert(prefs->nbWorkers >= 1);

                        /* test if compression is blocked
                         * either because output is slow and all buffers are full
                         * or because input is slow and no job can start while waiting for at least one buffer to be filled.
                         * note : exclude starting part, since currentJobID > 1 */
                        if ( (zfp.consumed == previous_zfp_update.consumed)   /* no data compressed : no data available, or no more buffer to compress to, OR compression is really slow (compression of a single block is slower than update rate)*/
                          && (zfp.nbActiveWorkers == 0)                       /* confirmed : no compression ongoing */

ext/zstd/programs/fileio.c  view on Meta::CPAN

                    if (zfp.currentJobID > lastJobID) {
                        DISPLAYLEVEL(6, "compression level adaptation check \n")

                        /* check input speed */
                        if (zfp.currentJobID > (unsigned)(prefs->nbWorkers+1)) {   /* warm up period, to fill all workers */
                            if (inputBlocked <= 0) {
                                DISPLAYLEVEL(6, "input is never blocked => input is slower than ingestion \n");
                                speedChange = slower;
                            } else if (speedChange == noChange) {
                                unsigned long long newlyIngested = zfp.ingested - previous_zfp_correction.ingested;
                                unsigned long long newlyConsumed = zfp.consumed - previous_zfp_correction.consumed;
                                unsigned long long newlyProduced = zfp.produced - previous_zfp_correction.produced;
                                unsigned long long newlyFlushed  = zfp.flushed  - previous_zfp_correction.flushed;
                                previous_zfp_correction = zfp;
                                assert(inputPresented > 0);
                                DISPLAYLEVEL(6, "input blocked %u/%u(%.2f) - ingested:%u vs %u:consumed - flushed:%u vs %u:produced \n",
                                                inputBlocked, inputPresented, (double)inputBlocked/inputPresented*100,
                                                (unsigned)newlyIngested, (unsigned)newlyConsumed,
                                                (unsigned)newlyFlushed, (unsigned)newlyProduced);
                                if ( (inputBlocked > inputPresented / 8)     /* input is waiting often, because input buffers is full : compression or output too slow */
                                  && (newlyFlushed * 33 / 32 > newlyProduced)  /* flush everything that is produced */
                                  && (newlyIngested * 33 / 32 > newlyConsumed) /* input speed as fast or faster than compression speed */
                                ) {
                                    DISPLAYLEVEL(6, "recommend faster as in(%llu) >= (%llu)comp(%llu) <= out(%llu) \n",
                                                    newlyIngested, newlyConsumed, newlyProduced, newlyFlushed);
                                    speedChange = faster;
                                }
                            }
                            inputBlocked = 0;
                            inputPresented = 0;
                        }

                        if (speedChange == slower) {
                            DISPLAYLEVEL(6, "slower speed , higher compression \n")

 view all matches for this distribution


Config-Hierarchical

 view release on metacpan or  search on metacpan

lib/Config/Hierarchical.pm  view on Meta::CPAN


This sub will be used when a warning is displayed. e.g. a configuration that is refused or an override.

=item DIE

Used when an error occurs. E.g. a locked variable is set.

=item DEBUG

If this option is set, Config::Hierarchical will call the sub before and after acting on the configuration.
This can act as a breakpoint in a debugger or allows you to pinpoint a configuration problem.

lib/Config/Hierarchical.pm  view on Meta::CPAN

		{
		$self->{INTERACTION}{DIE}->("$self->{NAME}: Invalid 'EVALUATOR' definition, expecting a sub reference at '$location'!") ;
		}
	}

# temporarely remove the locked categories till we have handled INITIAL_VALUES
my $category_locks ;

if(exists $self->{LOCKED_CATEGORIES})
	{
	if('ARRAY' ne ref $self->{LOCKED_CATEGORIES})

lib/Config/Hierarchical.pm  view on Meta::CPAN


Extra validators that will only be used during this call to B<Set>.

=item * FORCE_LOCK

If a variable is locked, trying to set it will generate an error. It is possible to temporarily force
the lock with this option. A warning is displayed when a lock is forced.

=item * LOCK

Will lock the variable if set to 1, unlock if set to 0.

lib/Config/Hierarchical.pm  view on Meta::CPAN

		) ;
	}
	
if(exists $self->{LOCKED_CATEGORIES}{$options{CATEGORY}})
	{
	$self->{INTERACTION}{DIE}->("$self->{NAME}: Variable '$options{CATEGORY}::$options{NAME}', category '$options{CATEGORY}' was locked at '$location'.\n") ;
	}

if
	(
	      exists $self->{CATEGORIES}{$options{CATEGORY}}{$options{NAME}}

lib/Config/Hierarchical.pm  view on Meta::CPAN

		{
		# not the same value
		
		unless(exists $config_variable->{LOCKED})
			{
			#~ Not locked, set
			$set_status .= 'OK.' ;
			}
		else
			{
			if($options->{FORCE_LOCK})
				{
				$set_status .= 'OK, forced lock.' ;
				$self->{INTERACTION}{WARN}->("$self->{NAME}: Forcing locked variable '$options->{CATEGORY}::$options->{NAME}' at '$location'.\n") ;
				}
			else 
				{
				$self->{INTERACTION}{DIE}->("$self->{NAME}: Variable '$options->{CATEGORY}::$options->{NAME}' was locked and couldn't be set at '$location'.\n") ;
				}
			}
		}
	else
		{

lib/Config/Hierarchical.pm  view on Meta::CPAN

sub LockCategories
{

=head2 LockCategories(@categories)

Locks the categories passed as argument. A variable in a locked category can not be set.
An attempt to set a locked variable will generate an error. B<FORCE_LOCK> has no effect on locked categories.

	$config->LockCategories('PARENT', 'OTHER') ;

I<Arguments>

lib/Config/Hierarchical.pm  view on Meta::CPAN

sub Lock
{

=head2 Lock(NAME => $variable_name, CATEGORY => $category)

Locks a variable in the default category or an explicit category. A locked variable can not be set.

To set a locked variable, B<FORCE_LOCK> can be used. B<FORCE_LOCK> usually pinpoints a problem
in your configuration.

  $config->Lock(NAME => 'CC') ;
  $config->Lock(NAME => 'CC', CATEGORY => 'PARENT') ;

lib/Config/Hierarchical.pm  view on Meta::CPAN

if($self->{VERBOSE})
	{
	$self->{INTERACTION}{INFO}->("$self->{NAME}: Checking Lock of '$options{CATEGORY}::$options{NAME}' at '$location'.\n") ;
	}
	
my $locked = undef ;

if(exists $self->{CATEGORIES}{$options{CATEGORY}}{$options{NAME}})
	{
	if(exists $self->{CATEGORIES}{$options{CATEGORY}}{$options{NAME}}{LOCKED})
		{
		$locked = 1 ;
		}
	else
		{
		$locked = 0 ;
		}
	}

return($locked) ;
}
  
#-------------------------------------------------------------------------------

sub Exists

 view all matches for this distribution


Config-IPFilter

 view release on metacpan or  search on metacpan

lib/Config/IPFilter.pm  view on Meta::CPAN


=head1 Description

    # Example of a "ipfilter.dat" file
    #
    # All entered IP ranges will be blocked in both directions. Be careful
    # what you enter here. Wrong entries may totally block access to the
    # network.
    #
    # Format:
    # IP-Range , Access Level , Description
    #
    # Access Levels:
    # 127 blocked
    # >=127 permitted

    064.094.089.000 - 064.094.089.255 , 000 , Gator.com

This entry will block the IPs from 064.094.089.000 to 064.094.089.255, i.e.

 view all matches for this distribution


Config-Inetd

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


 - Some inefficiency cleaned up.

0.07 2004/01/25

 - inetd.conf is locked.

0.03 2004/01/21

 - bin/inetd.pl added.

 view all matches for this distribution


Config-Model-Systemd

 view release on metacpan or  search on metacpan

lib/Config/Model/models/Systemd/Common/Exec.pl  view on Meta::CPAN

        ]
      },
      'SecureBits',
      {
        'description' => 'Controls the secure bits set for the executed process. Takes a space-separated combination of
options from the following list: C<keep-caps>, C<keep-caps-locked>,
C<no-setuid-fixup>, C<no-setuid-fixup-locked>, C<noroot>, and
C<noroot-locked>. This option may appear more than once, in which case the secure bits are
ORed. If the empty string is assigned to this option, the bits are reset to 0. This does not affect commands
prefixed with C<+>. See L<capabilities(7)> for
details.',
        'type' => 'leaf',
        'value_type' => 'uniline'

lib/Config/Model/models/Systemd/Common/Exec.pl  view on Meta::CPAN

      {
        'description' => 'Takes a boolean argument. If set, writes to the hardware clock or system clock will
be denied. Defaults to off. Enabling this option removes C<CAP_SYS_TIME> and
C<CAP_WAKE_ALARM> from the capability bounding set for this unit, installs a system
call filter to block calls that can set the clock, and C<DeviceAllow=char-rtc r> is
implied. Note that the system calls are blocked altogether, the filter does not take into account
that some of the calls can be used to read the clock state with some parameter combinations.
Effectively, C</dev/rtc0>, C</dev/rtc1>, etc. are made read-only
to the service. See
L<systemd.resource-control(5)>
for the details about C<DeviceAllow>.

lib/Config/Model/models/Systemd/Common/Exec.pl  view on Meta::CPAN

option. Specifically, it is recommended to combine this option with
C<SystemCallArchitectures=native> or similar.

Note that strict system call filters may impact execution and error handling code paths of the service
invocation. Specifically, access to the execve() system call is required for the execution
of the service binary \x{2014} if it is blocked service invocation will necessarily fail. Also, if execution of the
service binary fails for some reason (for example: missing service executable), the error handling logic might
require access to an additional set of system calls in order to process and log this failure correctly. It
might be necessary to temporarily disable system call filters in order to simplify debugging of such
failures.

lib/Config/Model/models/Systemd/Common/Exec.pl  view on Meta::CPAN

call may be used to execute operations similar to what can be done with the older
kill() system call, hence blocking the latter without the former only provides
weak protection. Since new system calls are added regularly to the kernel as development progresses,
keeping system call deny lists comprehensive requires constant work. It is thus recommended to use
allow-listing instead, which offers the benefit that new system calls are by default implicitly
blocked until the allow list is updated.

Also note that a number of system calls are required to be accessible for the dynamic linker to
work. The dynamic linker is required for running most regular programs (specifically: all dynamic ELF
binaries, which is how most distributions build packaged programs). This means that blocking these
system calls (which include open(), openat() or

 view all matches for this distribution


Config-Patch

 view release on metacpan or  search on metacpan

lib/Config/Patch.pm  view on Meta::CPAN

    my($self) = @_;

        # Ignore if locking wasn't requested
    return if ! $self->{flock};

        # Already locked?
    if($self->{locked}) {
        $self->{locked}++;
        return 1;
    }

    open my $fh, "+<$self->{file}" or 
        LOGDIE "Cannot open $self->{file} ($!)";

    flock($fh, LOCK_EX);

    $self->{fh} = $fh;

    $self->{locked} = 1;
}

###########################################
sub unlock {
###########################################
    my($self) = @_;

        # Ignore if locking wasn't requested
    return if ! $self->{flock};

    if(! $self->{locked}) {
            # Not locked?
        return 1;
    }

    if($self->{locked} > 1) {
            # Multiple lock released?
        $self->{locked}--;
        return 1;
    }

        # Release the last lock
    flock($self->{fh}, LOCK_UN);
    $self->{locked} = undef;
    1;
}

# LEGACY METHODS

 view all matches for this distribution


Config-Simple

 view release on metacpan or  search on metacpan

Simple.pm  view on Meta::CPAN

  unless ( sysopen(FH, $file, O_WRONLY|O_CREAT, 0666) ) {
    $self->error("'$file' couldn't be opened for writing: $!");
    return undef;
  }
  unless ( flock(FH, LOCK_EX) ) {
    $self->error("'$file' couldn't be locked: $!");
    return undef;
  }
  unless ( truncate(FH, 0) ) {
      $self->error("'$file' couldn't be truncated: $!");
      return undef;

 view all matches for this distribution


Config-Std

 view release on metacpan or  search on metacpan

lib/Config/Std.pm  view on Meta::CPAN


        open my $fh, '>', $filename
            or croak "Can't open config file '$filename' for writing (\L$!\E)";

        flock($fh,LOCK_EX|LOCK_NB)
            || croak "Can't write to locked config file '$filename'"
                if ! ref $filename;

        my $first = 1;
        for my $block ( @{$array_rep_for{$hash_ref}} ) {
            print {$fh} $block->serialize($first, scalar caller, $post_gap);

lib/Config/Std.pm  view on Meta::CPAN

        my ($filename, $hash_ref) = @_;

        open my $fh, '<', $filename
            or croak "Can't open config file '$filename' (\L$!\E)";
        flock($fh,LOCK_SH|LOCK_NB)
            || croak "Can't read from locked config file '$filename'"
                if !ref $filename;
        my $text = do{local $/; <$fh>};
        flock($fh,LOCK_UN) if !ref $filename;

        my @config_file = Config::Std::Block->new({ name=>q{}, first=>1 });

lib/Config/Std.pm  view on Meta::CPAN


You tried to read in a configuration file, but the file you specified
didn't exist. Perhaps the filepath you specified was wrong. Or maybe
your application didn't have permission to access the file you specified.

=item Can't read from locked config file '$filename'

You tried to read in a configuration file, but the file you specified
was being written by someone else (they had a file lock active on it).
Either try again later, or work out who else is using the file.

lib/Config/Std.pm  view on Meta::CPAN

You tried to update or create a configuration file, but the file you
specified could not be opened for writing (for the reason given in the
parentheses). This is often caused by incorrect filepaths or lack of
write permissions on a directory.

=item Can't write to locked config file '%s'

You tried to update or create a configuration file, but the file you
specified was being written at the time by someone else (they had a file
lock active on it). Either try again later, or work out who else is
using the file.

 view all matches for this distribution


Config-Trivial

 view release on metacpan or  search on metacpan

lib/Config/Trivial.pm  view on Meta::CPAN

    config_file => '/path/to/somewhere/else',
    configuration => $settings);

The method returns true on success. If the file already exists
then it is backed up first. The write is not 'atomic' or
locked for reading in anyway. If the file cannot be written to
then it will die.

Configuration data passed by this method is only written to
file, it is not stored in the internal configuration object.
To store data in the internal use the set_configuration data

 view all matches for this distribution


Const-Common

 view release on metacpan or  search on metacpan

lib/Const/Common.pm  view on Meta::CPAN

sub import {
    my $pkg   = caller;
    shift;
    my %constants = @_ == 1 ? %{ $_[0] } : @_;

    Data::Lock::dlock my $locked = \%constants;
    {
        no strict 'refs';
        ${ "$pkg\::_constants" } = $locked;
        for my $method (qw/const constants constant_names/) {
            *{ "$pkg\::$method" } = \&{ __PACKAGE__ . "::$method" };
        }
        push @{"$pkg\::ISA"}, ('Exporter');
        push @{"$pkg\::EXPORT"}, (keys %$locked);
    }

    require constant;
    @_ = ('constant', $locked);
    goto constant->can('import');
}

sub const {
    my ($pkg, $constant_name) = @_;

 view all matches for this distribution


Control-CLI-AvayaData

 view release on metacpan or  search on metacpan

lib/Control/CLI/AvayaData.pm  view on Meta::CPAN

	ersbanner	=>	"\x0d* Ethernet Routing Switch",
	passportbanner	=>	"\x0d* Passport 8",
	pp1600banner	=>	"\x0d* Passport 16", # The 6 ensures this does not trigger on old Accelar 1x00
	vspbanner	=>	"All Rights Reserved.\n\x0dVirtual Services Platform",
	consoleLogMsg1	=>	"connected via console port", #On serial port: GlobalRouter SW INFO user rwa connected via console port
	consoleLogMsg2	=>	"Blocked unauthorized ACLI access",
	more1		=>	'----More (q=Quit, space/return=Continue)----',
	more2		=>	'--More--',
	wlan9100banner	=>	'Avaya Wi-Fi Access Point',
);
my %Prm = ( # Hash containing list of named parameters returned by attributes

lib/Control/CLI/AvayaData.pm  view on Meta::CPAN

					. '|(?:parameter|object) .+? is out of range'
				. ')',
	$Prm{sr}		=>	'^('
					. '\s+\^\n.+'
					. '|Error : Command .+? does not exist'
					. '|Config is locked by some other user'
				. ')',
	$Prm{trpz}		=>	'^('
					. '\s+\^\n.+'
					. '|Unrecognized command:.+'
					. '|Unrecognized command in this mode:.+'

 view all matches for this distribution


Control-CLI-Extreme

 view release on metacpan or  search on metacpan

lib/Control/CLI/Extreme.pm  view on Meta::CPAN

	passportbanner	=>	"\x0d* Passport 8",
	pp1600banner	=>	"\x0d* Passport 16", # The 6 ensures this does not trigger on old Accelar 1x00
	vspbanner	=>	"All Rights Reserved.\n\x0dVirtual Services Platform",
	fabengbanner	=>	"Extreme Networks Fabric Engine",
	consoleLogMsg1	=>	"connected via console port", #On serial port: GlobalRouter SW INFO user rwa connected via console port
	consoleLogMsg2	=>	"Blocked unauthorized ACLI access",
	more1		=>	'----More (q=Quit, space/return=Continue)----',
	more2		=>	'--More--',
	wlan9100banner	=>	'Avaya Wi-Fi Access Point',
	xos		=>	'ExtremeXOS',
	switchEngine	=>	'Extreme Networks Switch Engine',

lib/Control/CLI/Extreme.pm  view on Meta::CPAN

					. '|(?:parameter|object) .+? is out of range'
				. ')',
	$Prm{sr}		=>	'^('
					. '\s+\^\n.+'
					. '|Error : Command .+? does not exist'
					. '|Config is locked by some other user'
				. ')',
	$Prm{trpz}		=>	'^('
					. '\s+\^\n.+'
					. '|Unrecognized command:.+'
					. '|Unrecognized command in this mode:.+'

 view all matches for this distribution


Convert-Binary-C

 view release on metacpan or  search on metacpan

MANIFEST  view on Meta::CPAN

tests/include/pdclib/functions/_tzcode/_PDCLIB_localtime_tzset.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_mktime_tzname.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_timesub.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_tzload.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_tzparse.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_tzset_unlocked.c
tests/include/pdclib/functions/_tzcode/_PDCLIB_update_tzname_etc.c
tests/include/pdclib/functions/_tzcode/Readme.txt
tests/include/pdclib/functions/ctype/isalnum.c
tests/include/pdclib/functions/ctype/isalpha.c
tests/include/pdclib/functions/ctype/isblank.c

 view all matches for this distribution


( run in 1.232 second using v1.01-cache-2.11-cpan-49f99fa48dc )