mirror of
https://github.com/adulau/aha.git
synced 2025-01-01 05:36:24 +00:00
sh: fix seq_file memory leak
When using single_open(), single_release() should be used instead of seq_release(), otherwise there is a memory leak. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
parent
c9272c4f9f
commit
45dabf1427
2 changed files with 2 additions and 2 deletions
|
@ -120,7 +120,7 @@ static const struct file_operations cache_debugfs_fops = {
|
|||
.open = cache_debugfs_open,
|
||||
.read = seq_read,
|
||||
.llseek = seq_lseek,
|
||||
.release = seq_release,
|
||||
.release = single_release,
|
||||
};
|
||||
|
||||
static int __init cache_debugfs_init(void)
|
||||
|
|
|
@ -385,7 +385,7 @@ static const struct file_operations pmb_debugfs_fops = {
|
|||
.open = pmb_debugfs_open,
|
||||
.read = seq_read,
|
||||
.llseek = seq_lseek,
|
||||
.release = seq_release,
|
||||
.release = single_release,
|
||||
};
|
||||
|
||||
static int __init pmb_debugfs_init(void)
|
||||
|
|
Loading…
Reference in a new issue