On Mon, Jul 19, 2021 at 03:15:37PM +0200, Martin Vahlensieck wrote:
> The code part for icmp{,6}-type is optional.  Below is a diff marking
> it as such.  Should the text be changed as well?

The text reads fine as is, no need to repeat that they're optional when
the brackets make it clear already.

> Or am I missing a reason why it is not marked optional?

No, pfctl(8)'s parser explicitly defines optional.
 
> Index: pf.conf.5
> ===================================================================
> RCS file: /cvs/src/share/man/man5/pf.conf.5,v
> retrieving revision 1.586
> diff -u -p -r1.586 pf.conf.5
> --- pf.conf.5 1 Feb 2021 00:31:04 -0000       1.586
> +++ pf.conf.5 19 Jul 2021 11:16:39 -0000
> @@ -564,8 +564,8 @@ Similar to
>  this rule only applies to packets of sockets owned by the specified
>  .Ar group .
>  .Pp
> -.It Cm icmp-type Ar type Cm code Ar code
> -.It Cm icmp6-type Ar type Cm code Ar code
> +.It Cm icmp-type Ar type Oo Cm code Ar code Oc
> +.It Cm icmp6-type Ar type Oo Cm code Ar code Oc

   .It Cm icmp-type Ar type Op Cm code Ar code
   .It Cm icmp6-type Ar type Op Cm code Ar code

mdoc(7)'s `.Op' is enough, which I just committed, thanks.

>  This rule only applies to ICMP or ICMP6 packets with the specified type
>  and code.
>  Text names for ICMP types and codes are listed in

Reply via email to