nuttx/libs/libc/stdio
Michal Lenc eea7db24f3 libc: add support for open_memstream
Adds support for POSIX interface open_memstream() that allows writing
to dynamic memory buffer stream. The stream is dynamically reallocated
as the buffer grows with initial size set to zero.

The caller has to free the buffer after the stream is closed.

The implementation uses fopencookie() for custom stream operations and
callbacks.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-11-29 02:13:19 -08:00
..
CMakeLists.txt libc: add support for memory buffer stream with fmemopen() 2023-10-27 08:55:24 +08:00
Kconfig libc/stdio: changed LIBC_NL_ARGMAX default value to 9 2023-08-03 19:07:22 -07:00
lib_asprintf.c
lib_clearerr.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_dprintf.c
lib_dtoa_data.c
lib_dtoa_engine.c nuttx: Use MIN/MAX definitions from "sys/param.h" 2023-02-01 23:47:44 +08:00
lib_dtoa_engine.h
lib_fclose.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_feof.c
lib_ferror.c
lib_fflush.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_fgetc.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_fgetpos.c
lib_fgets.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_fileno.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_fmemopen.c libc: add support for memory buffer stream with fmemopen() 2023-10-27 08:55:24 +08:00
lib_fopen.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_fopencookie.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_fprintf.c
lib_fputc.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_fputs.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_fputwc.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_fputws.c libs/libc/wchar: add fputws implementation 2023-09-22 08:51:07 +08:00
lib_fread.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_freopen.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_fscanf.c
lib_fseek.c
lib_fseeko.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_fsetpos.c
lib_ftell.c
lib_ftello.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_fwrite.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_getc.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_getchar.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_getdelim.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_gets_s.c libc/stdio: Make gets/gets_s work without CONFIG_FILE_STREAM 2023-02-24 10:39:48 +08:00
lib_gets.c libc/stdio: Make gets/gets_s work without CONFIG_FILE_STREAM 2023-02-24 10:39:48 +08:00
lib_libdgets.c libc/stdio: Make gets/gets_s work without CONFIG_FILE_STREAM 2023-02-24 10:39:48 +08:00
lib_libfflush.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_libfgets.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_libfilelock.c semantic/parser: fix compile warning found by sparse 2023-05-30 23:00:00 +08:00
lib_libflushall.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_libfread_unlocked.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_libfwrite.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_libgetstreams.c nxstyle: covert utf-8 to ascii 2023-07-14 01:24:50 +08:00
lib_libsprintf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_libvscanf.c the bug of sscanf exception output in arm64 platform 2023-11-15 03:45:32 -08:00
lib_libvsprintf.c Fix improper handling of 64 bit types for libvsprintf 2023-11-15 18:37:43 -08:00
lib_open_memstream.c libc: add support for open_memstream 2023-11-29 02:13:19 -08:00
lib_perror.c Indent the define statement by two spaces 2023-05-21 09:52:08 -03:00
lib_printf.c
lib_putc.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_putchar.c libs/libc: support unlock version for fread/fwrite/fputc/fgetc/... 2023-09-06 15:08:24 +03:00
lib_puts.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
lib_putwc.c libs/libc/wchar: add putwc implementation 2023-09-22 08:51:07 +08:00
lib_putwchar.c stdio: Implement [clearerr|putc|fflush]_unlocked 2023-10-29 17:09:18 +02:00
lib_rdflush_unlocked.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_remove.c libc: Change errno to set_errno and get_errno 2023-10-29 17:16:09 +02:00
lib_renameat.c libc: Add a new argument(size_t fulllen) to lib_getfullpath 2023-05-08 09:57:01 +02:00
lib_rewind.c libc/stdio: Add stdio file locking functions 2022-10-22 23:34:45 +08:00
lib_scanf.c
lib_setbuf.c
lib_setbuffer.c libc: Add setbuffer to stdio. 2023-05-01 11:24:41 +03:00
lib_setvbuf.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_snprintf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_sprintf.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_sscanf.c
lib_tempnam.c Fixes in asprintf usage. 2023-04-19 02:48:39 +08:00
lib_tmpfile.c
lib_tmpnam.c
lib_ultoa_invert.c Revert "libc/stdio: enable long long formating by CONFIG_HAVE_LONG_LONG" 2022-07-20 18:06:29 +03:00
lib_ultoa_invert.h Revert "libc/stdio: enable long long formating by CONFIG_HAVE_LONG_LONG" 2022-07-20 18:06:29 +03:00
lib_ungetc.c libc: add support for custom streams with fopencookie() 2023-10-18 21:13:01 +08:00
lib_vasprintf.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_vdprintf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_vfprintf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_vfscanf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_vprintf.c
lib_vscanf.c
lib_vsnprintf.c c++ compatibility: rename reserved c++ keywords 'public' and 'this' 2023-09-16 19:45:02 +08:00
lib_vsprintf.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_vsscanf.c libc/stdio: Change FILE buffer field from "unsigned char *" to "char *" 2023-10-22 21:18:46 +03:00
lib_wrflush_unlocked.c libc/stdio: Remove bforce from lib_fflush[_unlocked] 2023-10-29 17:09:18 +02:00
Make.defs libc: add support for open_memstream 2023-11-29 02:13:19 -08:00