Re: [PATCH] sysctl: Call sysctl_head_finish on error

From: Christoph Hellwig
Date: Wed Jun 24 2020 - 14:20:56 EST


On Wed, Jun 24, 2020 at 07:17:07PM +0100, Matthew Wilcox wrote:
> From: "Matthew Wilcox (Oracle)" <willy@xxxxxxxxxxxxx>
>
> This error path returned directly instead of calling sysctl_head_finish().

Looks good. But if you touch this anyway we also need to add the extra
byte to count for the write case (see the memdup_user_nul implementation).