Ticket #243 (closed defect: fixed)
SimpleFile Silo activation breaks site if /user/files does not exist and cannot be made
| Reported by: | skippy | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.5 |
| Component: | Habari Core Software | Version: | SVN |
| Keywords: | Cc: |
Description
If the directory /user/files does not exists when activating the SimpleFile media silo, and if the permissions on /user prevent the webserver from creating the /files directory, one sees the following error:
Error: mkdir() [function.mkdir]: Permission denied
/home/skippy/code/habari/system/plugins/simplefilesilo/simplefilesilo.plugin.php : Line 44
#0 in [core]:0:
Error::error_handler(
2,
'mkdir() [<a href=\'function.mkdir\'>function.mkdir</a>]: Permission denied',
'/home/skippy/code/habari/system/plugins/simplefilesilo/simplefilesilo.plugin.php',
44,
array (
)
)
#1 in system/plugins/simplefilesilo/simplefilesilo.plugin.php:44:
mkdir(
'/home/skippy/code/habari/user/files',
502
)
#2 in [core]:0:
SimpleFileSilo->action_init()
#3 in system/classes/plugins.php:67:
call_user_func_array(
array (
0 =>
SimpleFileSilo::__set_state(array(
'root' => '/home/skippy/code/habari/user/files',
'url' => 'http://localhost/habari/user/files',
'_added_templates' =>
array (
),
'_class_name' => '/home/skippy/code/habari/system/plugins/simplefilesilo/simplefilesilo.plugin.php',
'info' =>
InfoObject::__set_state(array(
'__inforecord_array' =>
array (
'name' =>
array (
'changed' => true,
'value' => 'Simple File Media Silo',
),
'version' =>
array (
'changed' => true,
'value' => '1.0',
),
'url' =>
array (
'changed' => true,
'value' => 'http://habariproject.org/',
),
'author' =>
array (
'changed' => true,
'...)
#4 in index.php:192:
Plugins::act(
'init'
)
Habari needs to check the permissions on /user prior to trying to invoke mkdir(), and needs to send a reasonable notification to the user.
Change History
Note: See
TracTickets for help on using
tickets.
