mirror of
https://github.com/libretro/RetroArch
synced 2025-02-04 21:40:02 +00:00
actually, let's just completely remove it
This commit is contained in:
parent
89f7afdc8f
commit
df55e6b4d1
@ -170,7 +170,6 @@ void filestream_set_size(RFILE *stream)
|
|||||||
**/
|
**/
|
||||||
RFILE *filestream_open(const char *path, unsigned mode, ssize_t unused)
|
RFILE *filestream_open(const char *path, unsigned mode, ssize_t unused)
|
||||||
{
|
{
|
||||||
ssize_t bufsize = 0x4000;
|
|
||||||
int flags = 0;
|
int flags = 0;
|
||||||
int mode_int = 0;
|
int mode_int = 0;
|
||||||
#if defined(HAVE_BUFFERED_IO)
|
#if defined(HAVE_BUFFERED_IO)
|
||||||
@ -191,7 +190,6 @@ RFILE *filestream_open(const char *path, unsigned mode, ssize_t unused)
|
|||||||
|
|
||||||
(void)mode_int;
|
(void)mode_int;
|
||||||
(void)flags;
|
(void)flags;
|
||||||
(void)bufsize;
|
|
||||||
|
|
||||||
stream->hints = mode;
|
stream->hints = mode;
|
||||||
|
|
||||||
@ -298,8 +296,6 @@ RFILE *filestream_open(const char *path, unsigned mode, ssize_t unused)
|
|||||||
if (!stream->fp)
|
if (!stream->fp)
|
||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
if (bufsize > 0)
|
|
||||||
{
|
|
||||||
/* Regarding setvbuf:
|
/* Regarding setvbuf:
|
||||||
*
|
*
|
||||||
* https://www.freebsd.org/cgi/man.cgi?query=setvbuf&apropos=0&sektion=0&manpath=FreeBSD+11.1-RELEASE&arch=default&format=html
|
* https://www.freebsd.org/cgi/man.cgi?query=setvbuf&apropos=0&sektion=0&manpath=FreeBSD+11.1-RELEASE&arch=default&format=html
|
||||||
@ -309,9 +305,8 @@ RFILE *filestream_open(const char *path, unsigned mode, ssize_t unused)
|
|||||||
*
|
*
|
||||||
* Since C89 does not support specifying a null buffer with a non-zero size, we create and track our own buffer for it.
|
* Since C89 does not support specifying a null buffer with a non-zero size, we create and track our own buffer for it.
|
||||||
*/
|
*/
|
||||||
stream->buf = (char*)calloc(1, bufsize);
|
stream->buf = (char*)calloc(1, 0x4000);
|
||||||
setvbuf(stream->fp, stream->buf, _IOFBF, bufsize);
|
setvbuf(stream->fp, stream->buf, _IOFBF, 0x4000);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user