On Wed, Jul 16, 2025 at 12:07:59PM +0200, Florian Westphal wrote: > Phil Sutter <phil@xxxxxx> wrote: > > On Wed, Jul 16, 2025 at 11:44:59AM +0200, Florian Westphal wrote: > > > Phil Sutter <phil@xxxxxx> wrote: > > > > #include <string.h> > > > > #include <stdlib.h> > > > > +#include <libmnl/libmnl.h> > > > > > > Why is this include needed? > > > > Because of: > > > > | In file included from udata.c:9: > > | ../include/utils.h:88:40: warning: 'struct nlattr' declared inside parameter list will not be visible outside of this definition or declaration > > | 88 | const char *mnl_attr_get_ifname(struct nlattr *attr); > > | | ^~~~~~ > > That struct is defined in linux/netlink.h. > > But you can add a foward declaration for this, i.e.: > > struct nlattr; > > As the layout isn't needed for the function declaration. ACK, will do!