From db65aa51d52ec2b4bd00b2f7835770779b19579c Mon Sep 17 00:00:00 2001 From: plegall Date: Fri, 29 Jan 2021 14:50:59 +0100 Subject: [PATCH] fixes #1297 check output buffer before cleaning it --- action.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/action.php b/action.php index 3b071bc68..aa983b78d 100644 --- a/action.php +++ b/action.php @@ -221,8 +221,12 @@ if (ini_get('safe_mode') == 0) @set_time_limit(0); } // Without clean and flush there may be some image download problems, or image can be corrupted after download -ob_clean(); -flush(); +if (ob_get_length() !== FALSE) +{ + ob_clean(); + flush(); +} + @readfile($file); ?>