From a87b86989611a7840a937eb93189b097544dbcd8 Mon Sep 17 00:00:00 2001 From: Sarjuuk Date: Tue, 28 May 2024 20:16:08 +0200 Subject: [PATCH] Setup/BLP * fix using replacement patch files as images --- setup/tools/imagecreatefromblp.func.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup/tools/imagecreatefromblp.func.php b/setup/tools/imagecreatefromblp.func.php index 758394fe..e239db76 100644 --- a/setup/tools/imagecreatefromblp.func.php +++ b/setup/tools/imagecreatefromblp.func.php @@ -57,10 +57,10 @@ // predict replacement patch files // ref: http://www.zezula.net/en/mpq/patchfiles.html - if (substr($data, 0x0, 0x4) == "PTCH") + if (substr($data, 0x0, 4) == "PTCH") { // strip patch header - if (substr($data, 0x40, 0x43) == "COPY") + if (substr($data, 0x40, 4) == "COPY") $data = substr($data, 0x44); else {