Re: pf: broken RB comparator drops IPv6 fragments

Alexandr Nedvedicky <[email protected]>
Newsgroups gmane.os.openbsd.bugs
Message-ID <[email protected]>
Hello,

On Fri, Apr 10, 2026 at 08:56:33AM +0200, Renaud Allard wrote:
</snip>
> 
> Index: sys/net/pf_norm.c
> ===================================================================
> --- sys/net/pf_norm.c
> +++ sys/net/pf_norm.c
> @@ -187,10 +187,10 @@ pf_frnode_compare(struct pf_frnode *a, s
>  static __inline int
>  pf_frag_compare(struct pf_fragment *a, struct pf_fragment *b)
>  {
> -	int	diff;
> -
> -	if ((diff = a->fr_id - b->fr_id) != 0)
> -		return (diff);
> +	if (a->fr_id > b->fr_id)
> +		return (1);
> +	if (a->fr_id < b->fr_id)
> +		return (-1);
> 
>  	return (0);
>  }
> 

    the diff above has been just committed [1]

thanks and
regards
sashan

[1] https://marc.info/?l=openbsd-cvs&m=177603594606794&w=2
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.