Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Fix user fields nullability to prevent SQL errors during injection
- Remove groups as import link field
- Fix `clean` function
- Prevent fatal error with `Safe\ini_set()`

## [2.15.1] - 2025-10-14

Expand Down
10 changes: 8 additions & 2 deletions inc/clientinjection.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
*/
use Glpi\Application\View\TemplateRenderer;
use Glpi\Debug\Profile;
use Glpi\Error\ErrorHandler;
use Safe\Exceptions\InfoException;

use function Safe\fclose;
use function Safe\filesize;
Expand Down Expand Up @@ -179,8 +181,12 @@ public static function processInjection(PluginDatainjectionModel $model, $entiti
/** @var array $CFG_GLPI */
global $CFG_GLPI;

// To prevent problem of execution time during injection
ini_set("max_execution_time", "0");
try {
ini_set("max_execution_time", "0");
} catch (InfoException $e) {
//empty catch -- but keep trace of issue
ErrorHandler::logCaughtException($e);
}

// Disable recording each SQL request in $_SESSION
Profile::getCurrent()->disable();
Expand Down