Re: [PATCH] cifs: fix return value for cifs_listxattr

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ronnie Sahlberg <lsahlber@xxxxxxxxxx> writes:
> If the application buffer was too small to fit all the names
> we would still count the number of bytes and return this for
> listxattr. This would then trigger a BUG in usercopy.c
>
> Fix the computation of the size so that we return -ERANGE
> correctly when the buffer is too small.
>
> This fixes the kernel BUG for xfstest generic/377

Good catch.

Reviewed-by: Aurelien Aptel <aaptel@xxxxxxxx>

Cheers,
-- 
Aurélien Aptel / SUSE Labs Samba Team
GPG: 1839 CB5F 9F5B FB9B AA97  8C99 03C8 A49B 521B D5D3
SUSE Linux GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)



[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux