ZF-9251: @ still generates errors in logs

Description

The isReadable method in Zend_Loader does an fopen on the filename to see if it is readable. Any errors are ignored by a preceding @. If a custom error-handler is defined, it will still be triggered though which is very annoying.

It can be easily fixed by first doing a file_exists() before attempting to open it.

Of course it can be reasoned the programmer should do this step himself, before asking if a file is readable. In that case Zend_Load_PluginLoader::load() (and possibly other methods in the framework) should be adjusted and do the file_exists() before calling isReadable.

Comments

The algorithm for Zend_Loader::isReadable() was updated for 1.10.1, and removed the error suppression operator (fopen() is no longer used).

Please always check against the most current version before creating reports to see if the issue still exists.

Ah, my mistake then.

This bug had been bothering me for a while. I recently downloaded the latest version and found it still existed but hadn't come around filing the bug report yet. I didn't think a new version had already been released in the short timespace since, let alone one that had discovered the bug and fixed it :-) What are the odds!

I'll be more careful next time ;-)