From ab2d7fd8bfb1eafc61953e74757e84ed407b1f21 Mon Sep 17 00:00:00 2001 From: David Oberhollenzer Date: Sun, 15 Sep 2019 17:34:39 +0200 Subject: Add an sqfs_file_t implementation for reading from STDIN Signed-off-by: David Oberhollenzer --- include/sqfs/io.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include/sqfs/io.h') diff --git a/include/sqfs/io.h b/include/sqfs/io.h index 0f980d6..a544875 100644 --- a/include/sqfs/io.h +++ b/include/sqfs/io.h @@ -142,6 +142,17 @@ extern "C" { */ SQFS_API sqfs_file_t *sqfs_open_file(const char *filename, int flags); +/** + * @brief Get a read-only file implementation that represents standard input + * + * This function creates a read-only file that represents STDIN. The file + * supports reading up to a specified number of bytes and only allows + * reading sequentially. + * + * @param size The alleged "size" of the file. + */ +SQFS_API sqfs_file_t *sqfs_get_stdin_file(uint64_t size); + #ifdef __cplusplus } #endif -- cgit v1.2.3