mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 17:04:59 +00:00
Kernel: Use ByteBuffer::zero_fill() instead of raw memset in Ext2
There was a typo in one of the memsets, use the type safe wrapper instead. Fix EXt
This commit is contained in:
parent
5e84320ecb
commit
7c950c2d01
1 changed files with 2 additions and 2 deletions
|
@ -343,7 +343,7 @@ KResult Ext2FS::write_block_list_for_inode(InodeIndex inode_index, ext2_inode& e
|
|||
|
||||
auto dind_block_contents = ByteBuffer::create_uninitialized(block_size());
|
||||
if (dind_block_new) {
|
||||
memset(dind_block_contents.data(), 0, dind_block_contents.size());
|
||||
dind_block_contents.zero_fill();
|
||||
dind_block_dirty = true;
|
||||
} else {
|
||||
auto buffer = UserOrKernelBuffer::for_kernel_buffer(dind_block_contents.data());
|
||||
|
@ -370,7 +370,7 @@ KResult Ext2FS::write_block_list_for_inode(InodeIndex inode_index, ext2_inode& e
|
|||
|
||||
auto ind_block_contents = ByteBuffer::create_uninitialized(block_size());
|
||||
if (ind_block_new) {
|
||||
memset(ind_block_contents.data(), 0, dind_block_contents.size());
|
||||
ind_block_contents.zero_fill();
|
||||
ind_block_dirty = true;
|
||||
} else {
|
||||
auto buffer = UserOrKernelBuffer::for_kernel_buffer(ind_block_contents.data());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue