diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-05-29 18:20:58 +0200 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-05-29 18:24:25 +0200 |
commit | 50b901d5ebdad40227de66cd5a0a0f62548f1563 (patch) | |
tree | 167e0da994a64a59164099b5d01b1e8aea8a5f66 /include/sqfs/block_processor.h | |
parent | cada7ca7d9386e68c38fc504c01bd2cac33dac44 (diff) |
Support associating a user pointer with data blocks
This commit modifies the block processor to support associating a user
data pointer with data blocks that it forwards to the block writer,
which is modified to accept an optional user data pointer.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'include/sqfs/block_processor.h')
-rw-r--r-- | include/sqfs/block_processor.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/sqfs/block_processor.h b/include/sqfs/block_processor.h index c88e3df..5c77155 100644 --- a/include/sqfs/block_processor.h +++ b/include/sqfs/block_processor.h @@ -168,6 +168,8 @@ sqfs_block_processor_t *sqfs_block_processor_create(size_t max_block_size, * @param inode An optional pointer to a pointer to an inode. If not NULL, the * block processor creates a file inode and stores a pointer to * it here and keeps updating the inode as the file grows. + * @param user An optional user data pointer that is passed to the + * the @ref sqfs_block_writer_t for each file data block. * @param flags A combination of @ref SQFS_BLK_FLAGS that can be used to * micro manage how the data is processed. * @@ -175,7 +177,7 @@ sqfs_block_processor_t *sqfs_block_processor_create(size_t max_block_size, */ SQFS_API int sqfs_block_processor_begin_file(sqfs_block_processor_t *proc, sqfs_inode_generic_t **inode, - sqfs_u32 flags); + void *user, sqfs_u32 flags); /** * @brief Append data to the current file. |