You need to sign in or sign up before continuing.
提交 f447fd30 编写于 作者: T Thomas Meyer 提交者: Chris Zankel

xtensa: Cocci spatch "noderef"

sizeof when applied to a pointer typed expression gives the size of the
pointer.
Found by coccinelle spatch "misc/noderef.cocci"
Signed-off-by: NThomas Meyer <thomas@m3y3r.de>
Signed-off-by: NChris Zankel <chris@zankel.net>
上级 cba9a900
...@@ -737,7 +737,8 @@ static int __init iss_net_setup(char *str) ...@@ -737,7 +737,8 @@ static int __init iss_net_setup(char *str)
return 1; return 1;
} }
if ((new = alloc_bootmem(sizeof new)) == NULL) { new = alloc_bootmem(sizeof(*new));
if (new == NULL) {
printk("Alloc_bootmem failed\n"); printk("Alloc_bootmem failed\n");
return 1; return 1;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册