staging: lustre: 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: Thomas Meyer <thomas@m3y3r.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Родитель
4a10c2ac2f
Коммит
430b849a5e
|
@ -1387,7 +1387,7 @@ echo_copyout_lsm (struct lov_stripe_md *lsm, void *_ulsm, int ulsm_nob)
|
|||
if (nob > ulsm_nob)
|
||||
return (-EINVAL);
|
||||
|
||||
if (copy_to_user (ulsm, lsm, sizeof(ulsm)))
|
||||
if (copy_to_user (ulsm, lsm, sizeof(*ulsm)))
|
||||
return (-EFAULT);
|
||||
|
||||
for (i = 0; i < lsm->lsm_stripe_count; i++) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче