|
From: | Andrew Westberg |
Subject: | Re: [lwip-users] LCP fails to negotiate options continuously after many previous successes |
Date: | Sun, 18 May 2014 08:16:26 -0400 |
Hello Andrew,
Yeah!, happy to hear that.
On Sun, May 18, 2014 at 07:36:06AM -0400, Andrew Westberg wrote:
> It's been running for over 15 hours on ppp_new without issue. I'd say the
> issue is solved.
I have to disagree. byte access is the only way to escape from alignment
> There may still be a bug in ppp.c with these two lines around 1762 if the
> platform isn't/can't support packed structs.
>
> *(payload++) = pcrx->in_protocol >> 8;
> *(payload) = pcrx->in_protocol & 0xFF;
>
> In the old ppp, these fields are set by fields after first casting to a
> header struct so packed or not makes no difference.
issues, this is what your compiler do for packed struct if your target
does not support unaligned access for short and long.
This is why all structures that are going to be used in buffers are
packed in lwIP, because the structure might be set to an unaligned
address in the buffer.
Anyway, lwIP is not designed to work with compilers that does not
support packed structures.
You're welcome :)
> Thanks for all your help!
Sylvain
_______________________________________________
lwip-users mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/lwip-users
[Prev in Thread] | Current Thread | [Next in Thread] |