Temporary file delete error hacked

Todo to check it