view release on metacpan or search on metacpan
lib/Apache/Config/Preproc/include.pm view on Meta::CPAN
return $self->{server_root};
}
sub context_string {
my ($self, $file) = @_;
my ($dev,$ino) = stat($file);
$file = abs_path($file);
return "\"$file\" $dev $ino";
}
sub context_push {
lib/Apache/Config/Preproc/include.pm view on Meta::CPAN
}
# Default included file table for unix-like OSes
sub _check_included_stat {
my ($self, $file) = @_;
my ($dev,$ino) = stat($file) or return 0;
return grep { $_->{dev} == $dev && $_->{ino} == $ino } @{$self->{context}};
}
# Path-based file table, for defective OSes (MSWin32)
sub _check_included_path {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/ConfigParser.pm view on Meta::CPAN
} else {
@paths = ($path);
}
foreach my $p (@paths) {
my @stat = stat($p);
unless (@stat) {
$self->{errstr} = "'$file_or_dir_name' line $line_number " .
"'$directive $path': stat of '$path' failed: $!";
# Check if missing file or directory errors should be ignored.
# This checks an undocumented object variable which is normally
lib/Apache/ConfigParser.pm view on Meta::CPAN
confess "$0: Apache::ConfigParser::parse_file $INCORRECT_NUMBER_OF_ARGS";
}
my ($self, $file_or_dir_name) = @_;
my @stat = stat($file_or_dir_name);
unless (@stat) {
$self->{errstr} = "cannot stat '$file_or_dir_name': $!";
return;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/DnsZone.pm view on Meta::CPAN
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
}
# is uid owner of dom_id
my ($domain, $domain_owner_id) = $dbh->domain_stat($dom_id);
unless (defined($domain_owner_id) && $uid == $domain_owner_id) {
$r->log_reason("User trying to hijack another domain");
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
lib/Apache/DnsZone.pm view on Meta::CPAN
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
}
# is uid owner of dom_id
my ($domain, $domain_owner_id) = $dbh->domain_stat($dom_id);
unless (defined($domain_owner_id) && $uid == $domain_owner_id) {
$r->log_reason("User trying to hijack another domain");
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
lib/Apache/DnsZone.pm view on Meta::CPAN
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
}
# is uid owner of dom_id
my ($domain, $domain_owner_id) = $dbh->domain_stat($dom_id);
unless (defined($domain_owner_id) && $uid == $domain_owner_id) {
$r->log_reason("User trying to hijack another domain");
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
lib/Apache/DnsZone.pm view on Meta::CPAN
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
}
# is uid owner of dom_id
my ($domain, $domain_owner_id) = $dbh->domain_stat($dom_id);
unless (defined($domain_owner_id) && $uid == $domain_owner_id) {
$r->log_reason("User trying to hijack another domain");
output_redirect($r, 1, '/admin');
$dbh->close();
return REDIRECT;
view all matches for this distribution
view release on metacpan or search on metacpan
# First time through, this creates an anonymous hash.
# On subsequent runs, the hash is cleared if $dirname's
# mtime has changed. This is how you get Apache::EnvDir
# to notice that files have gone away.
$dircfg->{mtime} ||= 0;
%$dircfg = () if (stat(_))[9] > $dircfg->{mtime};
$prefix ||= "";
$dircfg->{prefix} = $prefix;
$dircfg->{mtime} = (stat(_))[9];
local *DIR;
opendir(DIR, $dirname) || die "couldn't open $dirname\n";
local *FILE;
# Only do files.
next unless (-f $path && -r _);
# Skip files that havn't changed.
$dircfg->{file}{$file} ||= [0,""];
next unless (stat(_))[9] > $dircfg->{file}{$file}[0];
$changeflag++;
$dircfg->{file}{$file}[0] = (stat(_))[9];
if(open FILE, $path) {
$dircfg->{file}{$file}[1] = <FILE>;
$dircfg->{file}{$file}[1] =~ s/[\r\n]$//g;
close(FILE);
view all matches for this distribution
view release on metacpan or search on metacpan
FileManager.pm view on Meta::CPAN
#must be a file
elsif (-f $file) {
#get file size
my $stat = stat($file);
$size = $stat->size;
if ($size > 1024000) {
$size = sprintf("%0.2f",$size/1024000) . " <I>M</I>";
} elsif ($stat->size > 1024) {
$size = sprintf("%0.2f",$size/1024). " <I>K</I>";
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/FilteringProxy.pm view on Meta::CPAN
### XML CONFIGURATION
# get the modification time of the configuration file
# dev,ino,mode,nlink,uid,gid,rdev,size,atime,mtime,ctime,blksize,blocks
my @stat;
unless ((-r $config_file) and (@stat = stat($config_file))) {
$r->warn("could not stat '$config_file' ( FilteringProxyConfig )");
} else {
$r->warn("DEBUG: entering XML configuration");
my $mtime = $stat[9];
lib/Apache/FilteringProxy.pm view on Meta::CPAN
#my $config = my $doc = new XML::EasyOBJ(-type => 'file', -param => $config_file);
# we have just modified our file, so let's set our modification
# date to the new mod time so we don't keep causing ourself to
# reread the config
@stat = stat($config_file);
$mtime = $stat[9];
# log the configuration file modification stats
if (defined($Apache::FilteringProxy::config_modification)) {
$r->warn("config: modification time: current=$mtime,last=$Apache::FilteringProxy::config_modification");
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Gallery.pm view on Meta::CPAN
my $subr = $r->lookup_file($file);
$r->content_type($subr->content_type());
if ($::MP2) {
my $fileinfo = stat($file);
my $nonce = md5_base64($fileinfo->ino.$fileinfo->mtime);
if ($r->headers_in->{"If-None-Match"} eq $nonce) {
return Apache2::Const::HTTP_NOT_MODIFIED();
}
lib/Apache/Gallery.pm view on Meta::CPAN
$dirsortby=$r->dir_config('GalleryDirSortBy');
} else {
$dirsortby=$r->dir_config('GallerySortBy');
}
if ($dirsortby && $dirsortby =~ m/^(size|atime|mtime|ctime)$/) {
@directories = map(/^\d+ (.*)/, sort map(stat("$filename/$_")->$dirsortby()." $_", @directories));
} else {
@directories = sort @directories;
}
closedir(DIR);
lib/Apache/Gallery.pm view on Meta::CPAN
}
# Debian bug #619625 <http://bugs.debian.org/619625>
elsif (-f $thumbfilename && $thumbfilename =~ /$doc_pattern/i && $thumbfilename !~ /$img_pattern/i && ! -e $thumbfilename . ".ignore") {
my $type = lc($1);
my $stat = stat($thumbfilename);
my $size = $stat->size;
my $filetype;
if ($thumbfilename =~ m/\.(mpe?g|avi|mov|asf|wmv)$/i) {
$filetype = "video-$type";
lib/Apache/Gallery.pm view on Meta::CPAN
$dirsortby=$r->dir_config('GalleryDirSortBy');
} else {
$dirsortby=$r->dir_config('GallerySortBy');
}
if ($dirsortby && $dirsortby =~ m/^(size|atime|mtime|ctime)$/) {
@neighbour_directories = map(/^\d+ (.*)/, sort map(stat("$parent_filename/$_")->$dirsortby()." $_", @neighbour_directories));
} else {
@neighbour_directories = sort @neighbour_directories;
}
closedir(PARENT_DIR);
lib/Apache/Gallery.pm view on Meta::CPAN
if (-f $cache."/".$newfilename) {
$scale = 0;
# Check to see if the image has changed
my $filestat = stat($fullpath);
my $cachestat = stat($cache."/".$newfilename);
if ($filestat->mtime >= $cachestat->mtime) {
$scale = 1;
}
# Check to see if the .rotate file has been added or changed
if (-f $fullpath . ".rotate") {
my $rotatestat = stat($fullpath . ".rotate");
if ($rotatestat->mtime > $cachestat->mtime) {
$scale = 1;
}
}
# Check to see if the copyrightimage has been added or changed
if ($r->dir_config('GalleryCopyrightImage') && -f $r->dir_config('GalleryCopyrightImage')) {
unless ($width == $thumbnailwidth or $width == $thumbnailheight) {
my $copyrightstat = stat($r->dir_config('GalleryCopyrightImage'));
if ($copyrightstat->mtime > $cachestat->mtime) {
$scale = 1;
}
}
}
lib/Apache/Gallery.pm view on Meta::CPAN
if ($r->dir_config('GalleryUseFileDate') &&
($r->dir_config('GalleryUseFileDate') eq '1'
|| !$imageinfo->{"Picture Taken"} )) {
my $st = stat($file);
$imageinfo->{"DateTimeOriginal"} = $imageinfo->{"Picture Taken"} = scalar localtime($st->mtime) if $st;
}
return $imageinfo;
}
lib/Apache/Gallery.pm view on Meta::CPAN
my @files=@_;
my $sortby = $r->dir_config('GallerySortBy');
my $filename=$r->lookup_uri($r->uri)->filename;
$filename=(File::Spec->splitpath($filename))[1] if (-f $filename);
if ($sortby && $sortby =~ m/^(size|atime|mtime|ctime)$/) {
@files = map(/^\d+ (.*)/, sort map(stat("$filename/$_")->$sortby()." $_", @files));
} else {
@files = sort @files;
}
return @files;
}
view all matches for this distribution
view release on metacpan or search on metacpan
else { print "not ok\n"; }
if(-e 'htaccess') { print "ok 7\n"; }
else { print "not ok\n"; }
if( (stat('htaccess'))[7] > 0 ) { print "ok 8\n"; }
else { print "not ok\n"; }
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Imager/Resize.pm view on Meta::CPAN
$shrunk .= $suffix;
if (file_ok( $shrunk, $filename )) {
$r->filename($shrunk);
my $mtime = (stat( $shrunk ))[9];
utime time, $mtime, $shrunk;
return OK;
}
# if we're using a separate cache directory, the necessary subdirectory might not exist yet
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/JAF.pm view on Meta::CPAN
my $text = do { local $/; <IN> };
close IN;
unless ($TEMPLATES->{$_}{code} = Template::Document->new( $PARSER->parse($text) )) {
$TEMPLATES->{$_}{error} = $PARSER->error();
} else {
$TEMPLATES->{$_}{mtime} = (stat(_))[9];
}
}
}
sub load_templates {
lib/Apache/JAF.pm view on Meta::CPAN
$ref = $$t;
}
foreach my $p (@{$self->paths()}) {
my $full_name = "$p/$name";
if (exists $ref->{$full_name}) {
if ((stat($full_name))[9] > $ref->{$full_name}{mtime}) {
load_templates(undef, ref $self, $p);
no strict 'refs';
$ref = $$t;
}
return wantarray ? ($ref->{$full_name}{code}, $ref->{$full_name}{error}) : $ref->{$full_name}{code};
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Logmonster/Utility.pm view on Meta::CPAN
# get file attributes via stat
# (dev,ino,mode,nlink,uid,gid,rdev,size,atime,mtime,ctime,blksize,blocks)
$log->audit( "checking age of $file1 and $file2" );
my $stat1 = stat($file1)->mtime;
my $stat2 = stat($file2)->mtime;
$log->audit( "timestamps are $stat1 and $stat2");
return 1 if ( $stat2 > $stat1 );
return;
# I could just:
#
# if ( stat($f1)[9] > stat($f2)[9] )
#
# but that forces the reader to read the man page for stat
# to see what's happening
}
lib/Apache/Logmonster/Utility.pm view on Meta::CPAN
return $log->error( "file '$file' does not exist!", %args)
if !-e $file;
# one way to get file mode (using File::mode)
# my $raw_mode = stat($file)->[2];
## no critic
my $mode = sprintf "%04o", stat($file)->[2] & 07777;
# another way to get it
# my $st = stat($file);
# my $mode = sprintf "%lo", $st->mode & 07777;
$log->audit( "file $file has mode: $mode" );
return $mode;
}
lib/Apache/Logmonster/Utility.pm view on Meta::CPAN
if ( !-e $file ) {
$log->audit( "writing process id $PROCESS_ID to $file...");
$self->file_write( $file, lines => [$PROCESS_ID], %args) and return $file;
};
my $age = time() - stat($file)->mtime;
if ( $age < 1200 ) { # less than 20 minutes old
return $log->error( "check_pidfile: $file is " . $age / 60
. " minutes old and might still be running. If it is not running,"
. " please remove the file (rm $file).", %args);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/MONITOR.pm view on Meta::CPAN
elsif( $mon_string =~ /^mtime:(.+)$/ )
{
my $filename = $1;
print "$monitored_uri: checking file mtime of $filename\n";
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,
$atime,$mtime,$ctime,$blksize,$blocks) = stat($filename);
$modified_time = $mtime;
}
else
{
my $old_checksum = $state;
view all matches for this distribution
view release on metacpan or search on metacpan
my $self = shift;
my $dir = shift;
return DECLINED unless -d $dir;
my $last_modified = (stat(_))[9];
$self->r->headers_out->add('ETag' => sprintf("%lx-%s", $last_modified, $VERSION));
if (my $check = $self->r->headers_in->{"If-None-Match"}) {
my ($time, $ver) = $check =~ /^([a-f0-9]+)-([0-9.]+)$/;
(my $title = $subdir) =~ s/\s/$nb/og; # replace whitespace with
$title =~ s!^.*(/[^/]+/[^/]+)$!...$1!; # if dir is fully pathed, only keep 2 parts for title
my $uri = escape($subdir);
my $result;
my($atime,$mtime) = (stat($subdirpath))[8,9];
my($last,$times);
if($self->r->dir_config('CacheStats')){
($last,$times) = $self->stats($self->r->filename,$subdir);
}
view all matches for this distribution
view release on metacpan or search on metacpan
MiniWiki.pm view on Meta::CPAN
sub get_lastmod {
my ($filename) = @_;
my $lastmod = "never";
if (-f $filename) {
my $mtime = stat($filename)->mtime;
my $date = &ParseDateString("epoch $mtime");
$lastmod = &UnixDate($date, "%B %d, %Y %i:%M %p");
}
return "$lastmod";
MiniWiki.pm view on Meta::CPAN
# returns the timestamp of the given filename in the datadir
sub get_mtime($) {
my ($filename) = @_;
if (-f "$datadir/$filename") {
my $mtime = stat("$datadir/$filename")->mtime;
}
}
sub render($) {
my ($newtext) = @_;
MiniWiki.pm view on Meta::CPAN
my ($r, $uri, $revision) = @_;
my $fileuri = $datadir . "/" . uri_to_filename($uri);
my $thumburi = $datadir . "/THUMB_" . uri_to_filename($uri);
my $file_mtime = stat($fileuri)->mtime;
my ($subtype) = &is_img($uri);
#$r->send_http_header("image/$subtype");
if (-f $thumburi && stat($thumburi)->mtime > $file_mtime) {
# if the thumbnail is newer then the big image,
# then obviously a new one hasn't been uploaded.
# Don't call ImageMagick to check the size.
# Use the existing thumb.
return send_file($r, $thumburi);
MiniWiki.pm view on Meta::CPAN
if ($width < $max_width && $height < $max_height) {
# don't scale it down
return send_file($r, $fileuri);
}
else {
if (!-f $thumburi || stat($thumburi)->mtime < $file_mtime) {
my $resize_ratio;
if ($width > $height) {
# eg. .2 = 1200 / 240
$resize_ratio = $width / $max_width;
} else {
view all matches for this distribution
view release on metacpan or search on metacpan
if( fd < 0 )
XSRETURN_UNDEF;
if( !len ) {
struct stat st;
if( fstat( fd, &st ) == -1 )
XSRETURN_UNDEF;
len = st.st_size;
}
Newz( 0, ret, 1, Mmap );
view all matches for this distribution
view release on metacpan or search on metacpan
my @parloc = Apache->server->dir_config->get('PARInclude');
sub handler {
my $r = shift;
foreach (keys(%MTIME_LIST)) {
my $mtime = (stat($_))[9];
if($mtime > $MTIME_LIST{$_}) {
PAR::reload_libs($_);
if($UNPACK_LIST{$_}) {
unpack_par(undef, $_, Apache->server->dir_config->get('PARTempDir'))
}
if (DEBUG) {
warn "[PAR] archive has been unpacked previously\n";
warn "[PAR] directory age: ", -M $tmppar, "\n";
warn "[PAR] archive age: ", -M $par, "\n";
}
return $tmppar if (stat($tmppar))[9] > (stat($par))[9];
warn "[PAR] removing old unpack dir '$tmppar'" if DEBUG;
File::Path::rmtree $tmppar;
}
# XXX Add signature check here
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/PageKit.pm view on Meta::CPAN
sub _send_static_file {
my ( $pk, $filename ) = @_;
my $apr = $pk->{apr};
my $file_mtime = (stat($filename))[9];
my $ims = $apr->header_in('If-Modified-Since');
if ( $ims ) {
my $t = Apache::Util::parsedate($ims);
if ( $t && $file_mtime <= $t ) {
return HTTP_NOT_MODIFIED;
view all matches for this distribution
view release on metacpan or search on metacpan
ParseFormData.pm view on Meta::CPAN
my ($fh, $path) = @{$_->{'values'}};
seek($fh, 0, 0);
my %hash = (
filename => "",
type => exists($_->{'headers'}->{'content-type'}) ? $_->{'headers'}->{'content-type'} : "",
size => ($fh->stat())[7],
);
my $param = "";
for(@a) {
my ($name, $value) = (/([^=]+)=\"([^\"]+)\"/);
if($name eq "name") {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Reload.pm view on Meta::CPAN
my $TouchModules;
if ($TouchFile) {
warn "Checking mtime of $TouchFile\n" if $DEBUG;
my $touch_mtime = (stat($TouchFile))[9] || return 1;
return 1 unless $touch_mtime > $TouchTime;
$TouchTime = $touch_mtime;
my $sym = Apache->gensym;
open($sym, $TouchFile) || die "Can't open '$TouchFile': $!";
$TouchModules = <$sym>;
lib/Apache/Reload.pm view on Meta::CPAN
Schwartz's Stonehenge::Reload module that attempts to be a little
more intuitive and makes the usage easier. Stonehenge::Reload was
written by Randal to make specific modules reload themselves when
they changed. Unlike Apache::StatINC, Stonehenge::Reload only checked
the change time of modules that registered themselves with
Stonehenge::Reload, thus reducing stat() calls. Apache::Reload also
offers the exact same functionality as Apache::StatINC, and is thus
designed to be a drop-in replacement. Apache::Reload only checks modules
that register themselves with Apache::Reload if you explicitly turn off
the StatINC emulation method (see below). Like Apache::StatINC,
Apache::Reload must be installed as an Init Handler.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/SdnFw/lib/Core.pm view on Meta::CPAN
close F;
$return .= "</style>\n";
}
return $return;
# my $v = (stat("$s->{plib}/css/$stylefile.css"))[9];
# my $return = qq(\t<link rel="stylesheet" href="/css/$stylefile-r$v.css" />\n);
#
# # check for a custom stylesheet
# my $cv = (stat("/data/$s->{obase}/content/custom.css"))[9];
# if ($cv) {
# $return .= qq(\t<link rel="stylesheet" href="/custom-r$cv.css" />\n);
# }
#
# if ($s->{agent} eq 'iphone') {
view all matches for this distribution
view release on metacpan or search on metacpan
t/05_cache_opts.t view on Meta::CPAN
};
$session{ts} = time;
untie %session;
ok(-d "$cache_root/$ns", 'cache_root');
my $mode = (stat("$cache_root/$ns"))[2];
ok($mode & '0700', 'directory_umask');
Cache::FileCache::Clear($cache_root);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Session/Lock/File.pm view on Meta::CPAN
opendir(DIR, $dir) || die "Could not open directory $dir: $!";
my @files = readdir(DIR);
foreach my $file (@files) {
if ($file =~ /^Apache-Session.*\.lock$/) {
if ($now - (stat($dir.'/'.$file))[8] >= $time) {
if ($^O eq 'MSWin32') {
#Windows cannot unlink open file
unlink($dir.'/'.$file) || next;
} else {
open(FH, "+>$dir/".$file) || next;
view all matches for this distribution
view release on metacpan or search on metacpan
patches/Apache-Session-File-Lock1.54-patch view on Meta::CPAN
+++ Session/Lock/File.pm-patched 2004-01-23 16:29:13.000000000 +0100
@@ -133,7 +133,7 @@
my @files = readdir(DIR);
foreach my $file (@files) {
if ($file =~ /^Apache-Session.*\.lock$/) {
- if ((stat($dir.'/'.$file))[8] - $now >= $time) {
+ if ($now - (stat($dir.'/'.$file))[8] >= $time) {
open(FH, "+>$dir/".$file) || next;
flock(FH, LOCK_EX) || next;
unlink($dir.'/'.$file) || next;
view all matches for this distribution
view release on metacpan or search on metacpan
SetWWWTheme.pm view on Meta::CPAN
# we only want to deal with html files
return DECLINED unless $content_type eq 'text/html';
$filename = $r->filename; # get the filename we're looking for
unless (-e $r->finfo) # Apache does a stat() and puts the results in finfo,
# this is faster than testing the filename.
{
$r->log_error("File does not exist: $filename");
return NOT_FOUND;
}
view all matches for this distribution
view release on metacpan or search on metacpan
SimpleTemplate.pm view on Meta::CPAN
my $fun = $_cache{$_[0]};
my $usecache = $fun ? 1 : $s->{cache};
# check for updated template
if ($fun && ($s->{reload} > 0)) {
my $filetime = (stat($_[0]))[9];
if ($_cache_time{$_[0]} < $filetime) {
print STDERR "-- RELOADING ($package)\n" if ($s->{debug} > 1);
$fun = undef;
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
# then make will detect this and cause it to re-run over and over
# again. This is bad. Rather than taking action to touch it (which
# is unreliable on some platforms and requires write permissions)
# for now we should catch this and refuse to run.
if ( -f $0 ) {
my $s = (stat($0))[9];
# If the modification time is only slightly in the future,
# sleep briefly to remove the problem.
my $a = $s - time;
if ( $a > 0 and $a < 5 ) { sleep 5 }
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/SiteControl/UserFactory.pm view on Meta::CPAN
tied(%session)->delete;
next;
}
if(defined($usermap{$username})) {
# last modify time of session we saw
my $timea = (stat("$sessiondir/$usermap{$username}{_session_id}"))[9];
# last modify time of this session
my $timeb = (stat("$sessiondir/$id"))[9];
$r->log_error("User $username has duplicate session! Expiring old session");
if($timea < $timeb) {
# The one we saw earlier is older. Delete it.
untie %session;
tie %session, 'Apache::Session::File',
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/TS/AdminClient.pm view on Meta::CPAN
#!/usr/bin/perl
use Apache::TS::AdminClient;
my $cli = Apache::TS::AdminClient->new(%input);
my $string = $cli->get_stat("proxy.config.product_company");
print "$string\n";
=head1 DESCRIPTION:
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/Voodoo/Application/ConfigParser.pm view on Meta::CPAN
}
sub changed {
my $self = shift;
return $self->{'conf_mtime'} != (stat($self->{'conf_file'}))[9];
}
sub old_ns { return $_[0]->{'old_ns'} };
sub config { return $_[0]->{'config'} };
sub models { return $_[0]->{'models'} };
lib/Apache/Voodoo/Application/ConfigParser.pm view on Meta::CPAN
$conf{'dynamic_loading'} = $conf{'dynamic_loading'} || 0;
$conf{'halt_on_errors'} = defined($conf{'halt_on_errors'})?$conf{'halt_on_errors'}:1;
}
if ($conf{'dynamic_loading'}) {
$self->{'conf_mtime'} = (stat($self->{'conf_file'}))[9];
}
if (defined($conf{'database'})) {
my $db;
if (ref($conf{'database'}) eq "ARRAY") {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Apache/WebDAV.pm view on Meta::CPAN
}
}
my %wanted_properties = $self->get_wanted_properties($r);
# The list of properties in order which a stat() call must return.
my @properties = qw(dev ino mode nlink uid gid rdev getcontentlength
atime getlastmodified creationdate);
# Loop through all the files and call stat() on each one. Keep track of
# which properties the client requested.
my @results;
foreach my $path (@files)
{
lib/Apache/WebDAV.pm view on Meta::CPAN
{
$info->{'getcontenttype'} = 'httpd/unix-directory';
$info->{'resourcetype'} = 'collection';
}
@stat{@properties} = $handler->stat($path);
foreach my $prop (keys %wanted_properties)
{
# These are set above automatically, don't want to overwrite them
next if $prop eq 'resourcetype';
view all matches for this distribution