phpThumb
phpThumb copied to clipboard
file not existing warnings
Hi,
I've beginning to see similar error messages 2-3 months ago. Since, I see some each and every day. I updated to the latest phpthumb version but it's not fixed.
I don't understand, file existence is tested at line 585-586, but when the routine is executed, 2 warnings are issued about the file not existing and of course it doesn't exit.
L 585: if (@is_readable($phpThumb->cache_filename)) { RedirectToCachedFile(); }
Error log:
[03-Jan-2023 13:34:28 Europe/London] PHP Warning: md5_file(/home/website/public_html/phpthumb/cache//2/24/241/241c/phpThumb_cache_websitem.com__src241c8bc9a337c655007f0d9d648f0bb5_parc4c1605620aa671602749d7a607a8d05_dat1649164802.jpeg): failed to open stream: No such file or directory in /home/website/public_html/phpthumb/phpThumb.php on line 99 [03-Jan-2023 13:34:28 Europe/London] PHP Stack trace: [03-Jan-2023 13:34:28 Europe/London] PHP 1. {main}() /home/website/public_html/phpthumb/phpThumb.php:0 [03-Jan-2023 13:34:28 Europe/London] PHP 2. RedirectToCachedFile() /home/website/public_html/phpthumb/phpThumb.php:586 [03-Jan-2023 13:34:28 Europe/London] PHP 3. md5_file($filename = '/home/website/public_html/phpthumb/cache//2/24/241/241c/phpThumb_cache_websitem.com__src241c8bc9a337c655007f0d9d648f0bb5_parc4c1605620aa671602749d7a607a8d05_dat1649164802.jpeg') /home/website/public_html/phpthumb/phpThumb.php:99 [03-Jan-2023 13:34:28 Europe/London] PHP Warning: file_get_contents(/home/website/public_html/phpthumb/cache//2/24/241/241c/phpThumb_cache_websitem.com__src241c8bc9a337c655007f0d9d648f0bb5_parc4c1605620aa671602749d7a607a8d05_dat1649164802.jpeg): failed to open stream: No such file or directory in /home/website/public_html/phpthumb/phpThumb.php on line 109 [03-Jan-2023 13:34:28 Europe/London] PHP Stack trace: [03-Jan-2023 13:34:28 Europe/London] PHP 1. {main}() /home/website/public_html/phpthumb/phpThumb.php:0 [03-Jan-2023 13:34:28 Europe/London] PHP 2. RedirectToCachedFile() /home/website/public_html/phpthumb/phpThumb.php:586 [03-Jan-2023 13:34:28 Europe/London] PHP 3. file_get_contents($filename = '/home/website/public_html/phpthumb/cache//2/24/241/241c/phpThumb_cache_websitem.com__src241c8bc9a337c655007f0d9d648f0bb5_parc4c1605620aa671602749d7a607a8d05_dat1649164802.jpeg') /home/website/public_html/phpthumb/phpThumb.php:109
And of course, impossible to know what image or file caused this initially, I literally have hundreds of images using phpthumb.