From 958e1a758168b4908bcdd237518ab85b93d7e1bb Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Thu, 31 Dec 2009 12:37:48 +0000 Subject: Bug 519858 - Move uncommonly used parameters out of the "Required" section and into a "General" and "Advanced" section Patch by Max Kanat-Alexander r=LpSolit, a=LpSolit --- Bugzilla/Config.pm | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) (limited to 'Bugzilla/Config.pm') diff --git a/Bugzilla/Config.pm b/Bugzilla/Config.pm index ceb1861ed..0361592bf 100644 --- a/Bugzilla/Config.pm +++ b/Bugzilla/Config.pm @@ -35,6 +35,7 @@ use strict; use base qw(Exporter); use Bugzilla::Constants; use Bugzilla::Hook; +use Bugzilla::Install::Filesystem qw(fix_file_permissions); use Data::Dumper; use File::Temp; @@ -297,29 +298,13 @@ sub write_params { rename $tmpname, $param_file or die "Can't rename $tmpname to $param_file: $!"; - ChmodDataFile($param_file, 0666); + fix_file_permissions($param_file); # And now we have to reset the params cache so that Bugzilla will re-read # them. delete Bugzilla->request_cache->{params}; } -# Some files in the data directory must be world readable if and only if -# we don't have a webserver group. Call this function to do this. -# This will become a private function once all the datafile handling stuff -# moves into this package - -# This sub is not perldoc'd for that reason - noone should know about it -sub ChmodDataFile { - my ($file, $mask) = @_; - my $perm = 0770; - if ((stat(bz_locations()->{'datadir'}))[2] & 0002) { - $perm = 0777; - } - $perm = $perm & $mask; - chmod $perm,$file; -} - sub read_param_file { my %params; my $datadir = bz_locations()->{'datadir'}; -- cgit v1.2.3-24-g4f1b