mirror of
https://github.com/love2d/love.git
synced 2026-08-17 19:23:38 +02:00
Handle PHYSFS_fileExists failing with empty strings on windows
This commit is contained in:
@@ -110,8 +110,8 @@ namespace physfs
|
|||||||
{
|
{
|
||||||
bool isOpen = (file != 0);
|
bool isOpen = (file != 0);
|
||||||
|
|
||||||
if(!isOpen)
|
if(!isOpen && !open(READ))
|
||||||
open(READ);
|
throw love::Exception("Could not read file %s.", filename.c_str());
|
||||||
|
|
||||||
int max = (int)PHYSFS_fileLength(file);
|
int max = (int)PHYSFS_fileLength(file);
|
||||||
size = (size == ALL) ? max : size;
|
size = (size == ALL) ? max : size;
|
||||||
|
|||||||
Reference in New Issue
Block a user