From: Barijaona Ramaholimihaso Date: Sat, 22 Sep 2007 06:03:45 +0000 (+0000) Subject: Avoid "conditional and" for preparing file list in static rendering X-Git-Tag: debian/2.1.2-2~98 X-Git-Url: https://git.deb.at/?p=pkg%2Fblosxom.git;a=commitdiff_plain;h=2f585f8b41e5414917fd5b76c557e80474f6e4f2;hp=74eb1a75bb6accd3cda923bc1dfe6d2d1a877246 Avoid "conditional and" for preparing file list in static rendering --- diff --git a/blosxom.cgi b/blosxom.cgi index b80cfbc..f2861db 100755 --- a/blosxom.cgi +++ b/blosxom.cgi @@ -324,8 +324,8 @@ if (!$ENV{GATEWAY_INTERFACE} and param('-password') and $static_password and par foreach ( ('', split /\//, $path) ) { $p .= "/$_"; $p =~ s!^/!!; - $done{$p}++ and next; - (-d "$static_dir/$p" or $p =~ /\.$file_extension$/) or mkdir "$static_dir/$p", 0755; + next if $done{$p}++; + mkdir "$static_dir/$p", 0755 unless (-d "$static_dir/$p" or $p =~ /\.$file_extension$/); foreach $flavour ( @static_flavours ) { my $content_type = (&$template($p,'content_type',$flavour)); $content_type =~ s!\n.*!!s;