Fix unlinking readonly files throwing an Permission denied exception on Windows.
Fix unlinking readonly files throwing an Permission denied exception on Windows.

The file is checked before an unlink is tried. (this will make the tests run slower but is prefered over a if (!unlink { chmod; unlink }.
See also: http://stringoftheseus.com/blog/2010/12/22/php-unlink-permisssion-denied-error-on-windows/

Signed-off-by: Hans Donner <6b329e9ba587d6158ee01557207492dd61373475@pobox.com>

m4rcsch/lithium-core-library,UnionOfRAD/lithium,wbeater/lithium,whowgames/lithium,wbeater/lithium,qoqa/lithium,graphis/lithium,UnionOfRAD/lithium,whowgames/lithium,davidpersson/lithium,m4rcsch/lithium-core-library,muyehub/lithium,mehlah/lithium,jails/lithium,datachand/lithium,SensCritique/lithium,muyehub/lithium,davidpersson/lithium,mehlah/lithium,qoqa/lithium,pixelcog/lithium,datachand/lithium,graphis/lithium,pixelcog/lithium,SensCritique/lithium,jails/lithium