Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37714031
en ru br
Репозитории ALT
S:3.11.15-alt3
5.1: 1.9.16.20120217-alt3.M51.1
4.1: 1.9.2-alt1.cvs20080827.M41.3
4.0: 1.9.2-alt1.cvs20080827.M40.1
www.altlinux.org/Changes

Группа :: Сети/WWW
Пакет: moodle

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: moodle-alt-install-directorypermissions.patch
Скачать


 install.php | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/install.php b/install.php
index ac6c25e..1cf9f33 100644
--- a/install.php
+++ b/install.php
@@ -66,6 +66,7 @@ if ( empty($INSTALL['language']) and empty($_POST['language']) ) {
     $INSTALL['downloadlangpack']       = false;
     $INSTALL['showdownloadlangpack']   = true;
     $INSTALL['downloadlangpackerror']  = '';
+    $INSTALL['directorypermissions']  = 00777;
 
 /// To be used by the Installer
     $INSTALL['wwwroot']         = '';
@@ -137,7 +138,7 @@ $CFG->dirroot = $INSTALL['dirroot'];
 $CFG->libdir = $INSTALL['dirroot'].'/lib';
 $CFG->dataroot = $INSTALL['dataroot'];
 $CFG->admin = $INSTALL['admindirname'];
-$CFG->directorypermissions = 00777;
+$CFG->directorypermissions = $INSTALL['directorypermissions'];
 $CFG->running_installer = true;
 $CFG->docroot = 'http://docs.moodle.org';
 $CFG->httpswwwroot = $INSTALL['wwwrootform']; // Needed by doc_link() in Server Checks page.
@@ -552,7 +553,7 @@ if ($nextstage == SAVE) {
     $str .= '$CFG->admin     = \''.s($INSTALL['admindirname'],true)."';\r\n";
     $str .= "\r\n";
 
-    $str .= '$CFG->directorypermissions = 00777;  // try 02777 on a server in Safe Mode'."\r\n";
+    $str .= '$CFG->directorypermissions = '.sprintf("%05o",$INSTALL['directorypermissions']).';  // try 02777 on a server in Safe Mode'."\r\n";
     $str .= "\r\n";
 
     $str .= '$CFG->passwordsaltmain = \''.addsingleslashes(complex_random_string()).'\';'."\r\n";
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin