summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Userland/Libraries/LibC/stdio.cpp7
-rw-r--r--Userland/Libraries/LibC/stdio.h1
2 files changed, 8 insertions, 0 deletions
diff --git a/Userland/Libraries/LibC/stdio.cpp b/Userland/Libraries/LibC/stdio.cpp
index bc9091cd27..47bbc2e9b7 100644
--- a/Userland/Libraries/LibC/stdio.cpp
+++ b/Userland/Libraries/LibC/stdio.cpp
@@ -1067,6 +1067,13 @@ FILE* fdopen(int fd, const char* mode)
return FILE::create(fd, flags);
}
+// https://pubs.opengroup.org/onlinepubs/9699919799/functions/fmemopen.html
+FILE* fmemopen(void*, size_t, const char*)
+{
+ // FIXME: Implement me :^)
+ TODO();
+}
+
static inline bool is_default_stream(FILE* stream)
{
return stream == stdin || stream == stdout || stream == stderr;
diff --git a/Userland/Libraries/LibC/stdio.h b/Userland/Libraries/LibC/stdio.h
index c1bf665d19..8128beca77 100644
--- a/Userland/Libraries/LibC/stdio.h
+++ b/Userland/Libraries/LibC/stdio.h
@@ -57,6 +57,7 @@ int remove(const char* pathname);
FILE* fdopen(int fd, const char* mode);
FILE* fopen(const char* pathname, const char* mode);
FILE* freopen(const char* pathname, const char* mode, FILE*);
+FILE* fmemopen(void* buf, size_t size, const char* mode);
void flockfile(FILE* filehandle);
void funlockfile(FILE* filehandle);
int fclose(FILE*);