View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0033010 | mantisbt | administration | public | 2023-10-08 09:57 | 2023-10-31 16:32 |
Reporter | dregad | Assigned To | dregad | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Target Version | 2.26.0 | Fixed in Version | 2.26.0 | ||
Summary | 0033010: PHP errors triggered by Admin Checks cause silent failure | ||||
Description | If an Admin check throws an exception, it is caught by the default exception handler and MantisBT triggers an ERROR_PHP. This in turn is caught by check_error_handler(), which just stores it in $g_error_raised but as code execution can't continue it is never reported back to the end-user. This causes confusion and makes debugging / troubleshooting of the admin checks difficult. | ||||
Tags | No tags attached. | ||||
MantisBT: master ce841a23 2023-10-08 10:00 Details Diff |
Fix Admin Checks silently failing after Exception If an Admin check throws an exception, it is caught by the default exception handler and MantisBT triggers an ERROR_PHP. This in turn is caught by check_error_handler(), which just stores it in $g_error_raised, but since code execution can't continue it is never reported to the end-user, which causes confusion and makes debugging of the admin checks difficult. To avoid this, check_error_handler() now detects if it's processing an E_USER_ERROR of type ERROR_PHP and lets PHP handle it. Fixes 0033010 |
Affected Issues 0033010 |
|
mod - admin/check/check_api.php | Diff File |