Messages in this thread Patch in this message | | | Subject | [PATCH] proc: Fix bool initialization/comparison | From | Thomas Meyer <> | Date | Sat, 07 Oct 2017 16:02:21 +0200 |
| |
Bool initializations should use true and false. Bool tests don't need comparisons.
Signed-off-by: Thomas Meyer <thomas@m3y3r.de> ---
diff -u -p a/fs/proc/generic.c b/fs/proc/generic.c --- a/fs/proc/generic.c +++ b/fs/proc/generic.c @@ -325,7 +325,7 @@ static int proc_register(struct proc_dir write_lock(&proc_subdir_lock); dp->parent = dir; - if (pde_subdir_insert(dir, dp) == false) { + if (!pde_subdir_insert(dir, dp)) { WARN(1, "proc_dir_entry '%s/%s' already registered\n", dir->name, dp->name); write_unlock(&proc_subdir_lock);
| |