[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ed223a81-32c1-d339-b4e1-16b8fca88b2e@metafoo.de>
Date: Tue, 25 Oct 2016 21:11:21 +0200
From: Lars-Peter Clausen <lars@...afoo.de>
To: Colin King <colin.king@...onical.com>,
Jonathan Cameron <jic23@...nel.org>,
Hartmut Knaack <knaack.h@....de>,
Peter Meerwald-Stadler <pmeerw@...erw.net>,
sayli karnik <karniksayli1995@...il.com>,
Matt Ranostay <mranostay@...il.com>,
Wei Yongjun <weiyongjun1@...wei.com>, linux-iio@...r.kernel.org
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH] iio: maxim_thermocouple: return -EINVAL on invalid read
size
On 10/25/2016 09:04 PM, Colin King wrote:
> From: Colin Ian King <colin.king@...onical.com>
>
> In the case that the read size is not 2 or 4 bytes
> then maxim_thermocouple_read is not initializing ret and
> hence may return early with a bogus error return or
> just through to return with a bogos unread value in *val.
> Fix this by setting ret to -EINVAL for invalid (unhandled)
> read sizes.
>
> Signed-off-by: Colin Ian King <colin.king@...onical.com>
Again, Arnd already took the prize, https://lkml.org/lkml/2016/10/25/518
Powered by blists - more mailing lists