> -----Original Message----- > From: Ilya Maximets <[email protected]> > Sent: Monday 19 September 2022 12:50 > To: [email protected] > Cc: Finn, Emma <[email protected]>; Ilya Maximets <[email protected]> > Subject: [PATCH] sparse: Add a guard for netinet/ip6.h header on FreeBSD. > > Same as netinet/in.h, the netinet/ip6.h on FreeBSD requires sys/types.h to be > included first. So, adding a similar guard. > > We do have FreeBSD CI these days, but it is still nice to have a more clear > error > message. > > Fixes: b2befd5bb2db ("sparse: Add guards to prevent FreeBSD-incompatible > #include order.") > Signed-off-by: Ilya Maximets <[email protected]> > --- > include/sparse/netinet/ip6.h | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/include/sparse/netinet/ip6.h b/include/sparse/netinet/ip6.h index > bfa637a46..3beef3705 100644 > --- a/include/sparse/netinet/ip6.h > +++ b/include/sparse/netinet/ip6.h > @@ -18,6 +18,10 @@ > #error "Use this header only with sparse. It is not a correct > implementation." > #endif > > +#ifndef SYS_TYPES_H_INCLUDED > +#error "Must include <sys/types.h> before <netinet/ip6.h> for FreeBSD > support" > +#endif > + > #ifndef __NETINET_IP6_SPARSE > #define __NETINET_IP6_SPARSE 1 > > -- > 2.37.3
The change looks good to me. Acked-by: Emma Finn <[email protected]> _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
