Re: [PATCH 4/7] pipe: fix off-by-one error when checking buffer limits

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

 



On Sun, Jan 07, 2018 at 09:35:39PM -0800, Eric Biggers wrote:
> From: Eric Biggers <ebiggers@xxxxxxxxxx>
> 
> With pipe-user-pages-hard set to 'N', users were actually only allowed
> up to 'N - 1' buffers; and likewise for pipe-user-pages-soft.
> 
> Fix this to allow up to 'N' buffers, as would be expected.

Interesting. I was a bit surprized at first and found that this was
changed by b0b91d1 ("pipe: fix limit checking in pipe_set_size()").
Prior to this fix, only already allocated pipes were counted. After
the fix, an allocation attempt was made before checking the size. So
I think that your fix is needed in stable versions which backported
the commit above.

> Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx>

Acked-by: Willy Tarreau <w@xxxxxx>

Thanks,
Willy



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux