tl;dr: I fucking suck at coding (fix double free)

MRI: Filesystem: A garbage collected SDL_RWops file handle
will call close on itself even if 'close' was explicitly
called on it on the script side before.
This commit is contained in:
Jonas Kulla 2014-09-23 17:26:30 +02:00
parent 8d67b7c91d
commit 17efcbbbbd
1 changed files with 1 additions and 0 deletions

View File

@ -117,6 +117,7 @@ static int SDL_RWopsClose(SDL_RWops *ops)
return -1;
int result = PHYSFS_close(f);
ops->hidden.unknown.data1 = 0;
return (result != 0) ? 0 : -1;
}