lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] error introduced by commit acb4b60517572094bcd633c7df6fbd90


From: Stian Skjelstad
Subject: [lwip-devel] error introduced by commit acb4b60517572094bcd633c7df6fbd90836c4e2d icmp6_param_problem
Date: Thu, 12 Oct 2017 17:11:08 +0200

Hi

I just updated my tree to the master, and I now get an error when compiling with Keil (Armcc.exe V5.06).

lwip.git\src\core\ipv6\ip6.c(979): error:  #167: argument of type "__packed u16_t *" is incompatible with parameter of type "const void *"
          icmp6_param_problem(p, ICMP6_PP_FIELD, &ip6hdr->_plen);


In order to make it compile, I need to update the parameter to accept __packed pointer (unaligned access).

void icmp6_param_problem(struct pbuf *p, enum icmp6_pp_code c, const __packed void *pointer);


Currently, as far as I can see, cc.h does not define a macro to cherry-pick function parameters to be __packed. Another option is to typecast to (char *), but that feels very dirty.



--
Stian Skjelstad

reply via email to

[Prev in Thread] Current Thread [Next in Thread]