[TYPO3-core] RFC: Treat symlinks as executable

Ernesto Baschny [cron IT] ernst at cron-it.de
Tue Nov 7 14:42:09 CET 2006


Dmitry Dulepov schrieb:

> Michael Stucki wrote:
>> technically I agree with your solution, but practically this is just a
>> slowdown of the process, isn't it?
> 
> Link != executable. We have symlinks for directories too :)
> 
> $exec = $path . $cmd;
> is_executable(@is_link($exec) ? readlink($exec) : $exec))

And we have link to text files also. I agree with Dmitry and Martin that
 if we are doing a check, we should do it right. So calling readlink()
first seems to be a good solution.

The overhead to do this should be minimal compared to executing the
external binary afterwards.

Cheers,
Ernesto



More information about the TYPO3-team-core mailing list