Re: [PATCH] uapi: Prevent redefinition of struct iphdr
From: David Miller <davem@davemloft.net>
Date: 2019-12-26 00:34:32
Also in:
netdev
From: David Miller <davem@davemloft.net>
Date: 2019-12-26 00:34:32
Also in:
netdev
From: "A. Wilcox" <redacted> Date: Sun, 22 Dec 2019 00:02:27 -0600
@@ -83,6 +83,13 @@ #define IPV4_BEET_PHMAXLEN 8 +/* Allow libcs to deactivate this - musl has its own copy in <netinet/ip.h> */ + +#ifndef __UAPI_DEF_IPHDR +#define __UAPI_DEF_IPHDR 1 +#endif
How is this a musl-only problem? I see that glibc also defines struct iphdr in netinet/ip.h, so why doesn't it also suffer from this? I find it really strange that this, therefore, only happens for musl and we haven't had thousands of reports of this conflict with glibc over the years. I want an explanation, and suitably appropriate adjustments to the commit message and comments of this change. Thank you.