php - Corrupt files for no reason

one text

I am using the TCPDF plugin to create some pdfs of various sizes, after updating to PHP 8.0.12 every day the tcpdf.php file is "corrupt" giving in the logs this error:

Undefined variable $w in /tecnickcom/tcpdf/tcpdf.php on line 6417

However, the problem does not seem to exist, in fact, replacing the file by adding a space, for example, everything returns to work.
Has anyone ever something like this?
I was almost thinking of automatically replacing (if you can) the file every day.

Source