diff options
author | Stefano Brivio <sbrivio@redhat.com> | 2021-10-21 04:26:08 +0200 |
---|---|---|
committer | Stefano Brivio <sbrivio@redhat.com> | 2021-10-21 04:26:08 +0200 |
commit | dd942eaa480a0744fd64844f34233900a0da6893 (patch) | |
tree | 42f048af444890506e208d0058c5cd3e03718667 /dhcp.c | |
parent | 6257a2752e39c55bfb03d6db94af0c6033feb8df (diff) | |
download | passt-dd942eaa480a0744fd64844f34233900a0da6893.tar passt-dd942eaa480a0744fd64844f34233900a0da6893.tar.gz passt-dd942eaa480a0744fd64844f34233900a0da6893.tar.bz2 passt-dd942eaa480a0744fd64844f34233900a0da6893.tar.lz passt-dd942eaa480a0744fd64844f34233900a0da6893.tar.xz passt-dd942eaa480a0744fd64844f34233900a0da6893.tar.zst passt-dd942eaa480a0744fd64844f34233900a0da6893.zip |
passt: Fix build with gcc 7, use std=c99, enable some more Clang checkers
Unions and structs, you all have names now.
Take the chance to enable bugprone-reserved-identifier,
cert-dcl37-c, and cert-dcl51-cpp checkers in clang-tidy.
Provide a ffsl() weak declaration using gcc built-in.
Start reordering includes, but that's not enough for the
llvm-include-order checker yet.
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'dhcp.c')
-rw-r--r-- | dhcp.c | 17 |
1 files changed, 9 insertions, 8 deletions
@@ -12,23 +12,24 @@ * Author: Stefano Brivio <sbrivio@redhat.com> */ -#include <stdio.h> +#include <arpa/inet.h> +#include <net/if.h> +#include <netinet/if_ether.h> +#include <netinet/ip.h> +#include <netinet/udp.h> #include <stddef.h> +#include <stdio.h> #include <stdint.h> #include <unistd.h> #include <string.h> -#include <linux/if_ether.h> -#include <linux/ip.h> + #include <linux/ipv6.h> -#include <linux/udp.h> -#include <net/if.h> -#include <arpa/inet.h> -#include "checksum.h" #include "util.h" +#include "checksum.h" #include "passt.h" -#include "dhcp.h" #include "tap.h" +#include "dhcp.h" /** * struct opt - DHCP option |