From 25132d82f23bb2469bf0370a82f37091aaa13426 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Fri, 18 May 2012 17:24:59 +0200 Subject: [PATCH] Check whether bzdecompress is available --- wcfsetup/install/files/lib/system/io/Zip.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wcfsetup/install/files/lib/system/io/Zip.class.php b/wcfsetup/install/files/lib/system/io/Zip.class.php index b6f2f22048..348cc518ee 100644 --- a/wcfsetup/install/files/lib/system/io/Zip.class.php +++ b/wcfsetup/install/files/lib/system/io/Zip.class.php @@ -307,7 +307,8 @@ class Zip extends File implements IArchive { $content = gzinflate($content); break; case 12: - $content = bzdecompress($content); + if (function_exists('bzdecompress')) $content = bzdecompress($content); + else throw new SystemException('The bzip2 extension is not available'); case 0: break; default: -- 2.20.1