mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Fix lines iterator not closing opened files
This commit is contained in:
@@ -524,6 +524,11 @@ namespace physfs
|
||||
// Set the beginning of the next line.
|
||||
if(!file->eof())
|
||||
file->seek(newline+1);
|
||||
else if(close)
|
||||
{
|
||||
file->close();
|
||||
file->release();
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
@@ -534,7 +539,6 @@ namespace physfs
|
||||
file->release();
|
||||
}
|
||||
|
||||
// else: (newline <= 0)
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user