Add the fmemopen() and open_memstream() POSIX extensions to libroot. Those can be used to build FILE pointers to in-memory buffers, a possible use would be to make resources available to ported applications. Untested.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37997 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
François Revol 2010-08-10 09:56:13 +00:00
parent 3a5082aa46
commit 3d08ac9237
2 changed files with 7 additions and 0 deletions

View File

@ -95,6 +95,10 @@ extern FILE *popen(const char *command, const char *mode);
extern int pclose(FILE *stream);
extern void perror(const char *errorPrefix);
/* memory streams */
extern FILE *fmemopen(void *buf, size_t size, const char *mode);
extern FILE *open_memstream(void **buf, size_t *size);
/* file I/O */
extern int fflush(FILE *stream);
extern int fflush_unlocked(FILE *stream);

View File

@ -30,6 +30,7 @@ MergeObject posix_gnu_libio.o :
filedoalloc.c
fileops.c
flockfile.c
fmemopen.c
fputc.c
fputc_u.c
freopen.c
@ -49,6 +50,7 @@ MergeObject posix_gnu_libio.o :
iofgets.c
iofgets_u.c
iofopen.c
iofopncook.c
iofputs.c
iofputs_u.c
iofread.c
@ -72,6 +74,7 @@ MergeObject posix_gnu_libio.o :
iovdprintf.c
iovsprintf.c
iovsscanf.c
memstream.c
# obprintf.c
pclose.c
peekc.c