Prevent leaks

This commit is contained in:
twinaphex 2017-09-29 21:29:34 +02:00
parent 4fd00ac146
commit 542f87bf55

View File

@ -62,6 +62,7 @@
#endif
#include <streams/file_stream.h>
#include <string/stdstring.h>
#include <memmap.h>
#include <retro_miscellaneous.h>
@ -567,7 +568,7 @@ int filestream_close(RFILE *stream)
if (!stream)
goto error;
if (stream->ext)
if (stream->ext && !string_is_empty(stream->ext))
free(stream->ext);
#if defined(PSP)