]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commit
mke2fs: factor out 'write_all()' functionality
authorAllison Karlitskaya <allison.karlitskaya@redhat.com>
Mon, 25 Nov 2024 08:46:30 +0000 (09:46 +0100)
committerTheodore Ts'o <tytso@mit.edu>
Fri, 23 May 2025 17:53:16 +0000 (13:53 -0400)
commit167719dce93fb34cba459298ddfad32cf2c2e73a
tree78bf1d9e784010fc4c9ce817994a46fd6fd0b3d0
parentcddc1ddbe815ba7cb132ca6be3e67d46d97ed63e
mke2fs: factor out 'write_all()' functionality

When writing data to an inode (with mke2fs -d) we need to do the typical
loop to handle partial writes to make sure all of the data gets written.

Move that code to its own function.  This function also takes an offset
parameter, which makes it feel a bit like pwrite() (except that it does
modify the file offset).

Signed-off-by: Allison Karlitskaya <allison.karlitskaya@redhat.com>
misc/create_inode.c