diff --git a/Kbuild b/Kbuild index 0a47ec4..57f1c6d 100644 --- a/Kbuild +++ b/Kbuild @@ -1,3 +1,3 @@ obj-m := kyoutubeUnblock.o kyoutubeUnblock-objs := kytunblock.o mangle.o quic.o utils.o kmod_utils.o -ccflags-y := -std=gnu11 -DKERNEL_SPACE -Wno-error +ccflags-y := -std=gnu11 -DKERNEL_SPACE -Wno-error -Wno-declaration-after-statement diff --git a/kytunblock.c b/kytunblock.c index 6d51378..6ed9e07 100644 --- a/kytunblock.c +++ b/kytunblock.c @@ -9,7 +9,6 @@ #include #include #include -#include #include #include diff --git a/types.h b/types.h index c807e18..23cac9f 100644 --- a/types.h +++ b/types.h @@ -32,6 +32,7 @@ typedef __u64 uint64_t; #include // IWYU pragma: export #include // IWYU pragma: export #include // IWYU pragma: export +#include #define ip6_hdr ipv6hdr diff --git a/utils.c b/utils.c index f31d427..5f4c5f1 100644 --- a/utils.c +++ b/utils.c @@ -7,6 +7,13 @@ #include #include #include +#else +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 24)) + #include + #include +#else + #include +#endif #endif