[PATCH 4/5] Gate including net/ethernet.h on HAVE_NET_ETHERNET_H

Dan Fandrich dan at coneharvesters.com
Fri Jun 10 04:58:47 UTC 2011


On Fri, Jun 10, 2011 at 05:18:39AM +0200, Denys Vlasenko wrote:
> On Friday 10 June 2011 01:00, Dan Fandrich wrote:
> -#include <net/if.h>
> -#include <net/if_packet.h>
> -#include <netpacket/packet.h>
> -#include <net/ethernet.h>
> -
>  #include "ip_common.h"  /* #include "libbb.h" is inside */
>  #include "rt_names.h"
>  #include "utils.h"
>  
> +#include <net/if.h>
> +#include <net/if_packet.h>
> +#include <netpacket/packet.h>
> +#include <netinet/if_ether.h>
> 
> 
> If it is needed, then you need to add a comment why.

At one point I had an #ifdef HAVE_NET_ETHERNET_H in there, which meant that
#include "ip_common.h" had to be included first. I just left it in for
consistency with the others--there should be no problem leaving it out.

>>> Dan


More information about the busybox mailing list