提交 9aead435 编写于 作者: Y yanhai zhu 提交者: Chris Mason

Btrfs: Fix memset length in btrfs_file_write

Signed-off-by: NChris Mason <chris.mason@oracle.com>
上级 52c26179
......@@ -1094,7 +1094,7 @@ static ssize_t btrfs_file_write(struct file *file, const char __user *buf,
PAGE_CACHE_SHIFT;
WARN_ON(num_pages > nrptrs);
memset(pages, 0, sizeof(pages));
memset(pages, 0, sizeof(struct page *) * nrptrs);
ret = btrfs_check_free_space(root, write_bytes, 0);
if (ret)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册