View Issue Details

IDProjectCategoryView StatusLast Update
0026458mantisbtcode cleanuppublic2019-12-23 01:50
ReporterWepl Assigned Todregad  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionwon't fix 
Product Version1.3.20 
Summary0026458: deprecated __autoload function
Description

There are still errors caused by using deprecated __autoload function.

[10-Dec-2019 14:17:29 Europe/Berlin] PHP Deprecated: autoload() is deprecated, use spl_autoload_register() instead in /xxxx/mantisbt-1.3.20/library/phpmailer/PHPMailerAutoload.php on line 45
[10-Dec-2019 14:17:31 Europe/Berlin] PHP Deprecated:
autoload() is deprecated, use spl_autoload_register() instead in /xxxx/mantisbt-1.3.20/library/phpmailer/PHPMailerAutoload.php on line 45
[10-Dec-2019 14:17:40 Europe/Berlin] PHP Deprecated: __autoload() is deprecated, use spl_autoload_register() instead in /xxxx/mantisbt-1.3.20/library/phpmailer/PHPMailerAutoload.php on line 45

Solution 0023710 seems not to cover all places where __autoload is used.

Steps To Reproduce

Tested with PHP 7.2.19

TagsNo tags attached.

Relationships

related to 0025129 closedatrol Remove usage of deprecated function __autoload 

Activities

dregad

dregad

2019-12-10 11:46

developer   ~0063244

The deprecation notice is triggered by PHPMailer. MantisBT 1.3.x relies on version 5.2 of this library, and we are already using the latest available version (5.2.27). PHP 5.x is not supported anymore, and migrating to PHPMailer 6.x is well beyond the scope of changes that we would consider for the legacy branch, (critical bug and security fixes only).

Note that __autoload() method is deprecated, but still fully functional. It is not expected to be removed until PHP 8.0.

Therefore, we're not going to fix this. If the warning in your error log bothers you, you should suppress E_DEPRECATED notices by setting _errorreporting as appropriate in your php.ini.

I recommend you upgrade to MantisBT 2.x.