Re: [PATCH 10/12] bloom: encode out-of-bounds filters as non-empty

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

 



On Wed, Sep 09, 2020 at 11:23:48AM -0400, Taylor Blau wrote:
> -		filter->data = NULL;
> -		filter->len = 0;
> +		filter->data = xmalloc(1);
> +		filter->data[0] = 0xFF;
> +		filter->len = 1;
>
>  		if (computed)
>  			*computed |= BLOOM_TRUNC_LARGE;

Oops, I missed the case that added by the previous patch where the
number of diff entries is smaller than the limit, but the hashmap
entries (after directories are added and such) crosses the threshold.

Specifically, this patch doesn't write the 0xFF filter like it should.
I'll send a different version of this patch tomorrow.

Thanks,
Taylor



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux