[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Crashes and memory corruption in etharp.c under heavy A
Re: [lwip-users] Crashes and memory corruption in etharp.c under heavy ARP load
Thu, 12 Feb 2015 11:25:05 +0100
Lars Ole Pontoppidan wrote:
> It seems etharp.c is not written in a thread safe manner, while at the
> same time being accessed by both the tcpip task in lwIP and the
> application using lwIP. How can this ever be safe?
It can't: your're using lwIP in a wrong way: with multithreading, the raw API
must not be called from any other thread than the tcpip_thred. When trying to
send something spontaneously, use tcpip_callback() to get your function
executed in that thread.