projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9d8072e
)
autofs4 - autofs4_catatonic_mode(): remove redundant null check on kfree()
author
Tim Gardner
<
[email protected]
>
Fri, 1 Mar 2013 11:46:48 +0000
(19:46 +0800)
committer
Linus Torvalds
<
[email protected]
>
Fri, 1 Mar 2013 20:04:39 +0000
(12:04 -0800)
smatch analysis:
fs/autofs4/waitq.c:46 autofs4_catatonic_mode() info: redundant null check on wq->name.name calling kfree()
Signed-off-by: Tim Gardner <
[email protected]
>
Signed-off-by: Ian Kent <
[email protected]
>
Cc:
[email protected]
Signed-off-by: Linus Torvalds <
[email protected]
>
fs/autofs4/waitq.c
patch
|
blob
|
history
diff --git
a/fs/autofs4/waitq.c
b/fs/autofs4/waitq.c
index 03bc1d347d8e58f41ae2d1facda91e3deee470ee..3db70dae40d3a842de562c9fb4e26c29f9284239 100644
(file)
--- a/
fs/autofs4/waitq.c
+++ b/
fs/autofs4/waitq.c
@@
-42,10
+42,8
@@
void autofs4_catatonic_mode(struct autofs_sb_info *sbi)
while (wq) {
nwq = wq->next;
wq->status = -ENOENT; /* Magic is gone - report failure */
- if (wq->name.name) {
- kfree(wq->name.name);
- wq->name.name = NULL;
- }
+ kfree(wq->name.name);
+ wq->name.name = NULL;
wq->wait_ctr--;
wake_up_interruptible(&wq->queue);
wq = nwq;