View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0025734||mantisbt||administration||public||2019-05-04 06:31||2019-06-14 02:39|
|Target Version||2.21.1||Fixed in Version||2.21.1|
|Summary||0025734: LOGFILE_NOT_WRITABLE error triggered if file does not exist|
When MantisBT tries to write an event to a log file that does not already exist, a warning is printed _The file specified in $g_logdestination "/path/to/mantis.log" is not writable and the file is not created even if PHP process has write access. The event is added to the PHP system log.
This is a regression introduced by 0019642, as the code only checks that the target file is writable.
|Tags||No tags attached.|
MantisBT: master-2.21 1c1ffd3b
Committer: GitHub Details Diff
|log_event() create log file if it does not exist (0001509)
log_event() create log file if it does not exist
This is a regression from issue 0019642. When MantisBT tries to write an
event to a log file that does not already exist, a warning is printed
and the file is not created even if PHP process has write access to the
directory. The event is added to the PHP system log.
Instead of relying on is_writable(), the code now calls error_log() with
errors suppressed, then checks the result of the function call to
determine if the operation was successful or not.
|mod - core/logging_api.php||Diff File|
|2019-05-04 06:31||dregad||New Issue|
|2019-05-04 06:31||dregad||Status||new => assigned|
|2019-05-04 06:31||dregad||Assigned To||=> dregad|
|2019-05-04 06:31||dregad||Issue generated from: 0019642|
|2019-05-04 06:31||dregad||Relationship added||related to 0019642|
|2019-05-04 06:57||dregad||Note Added: 0062024|
|2019-05-05 12:34||dregad||Changeset attached||=> MantisBT master-2.21 1c1ffd3b|
|2019-05-05 12:34||dregad||Status||assigned => resolved|
|2019-05-05 12:34||dregad||Resolution||open => fixed|
|2019-05-05 13:56||atrol||Fixed in Version||=> 2.21.1|
|2019-06-14 02:39||vboctor||Status||resolved => closed|