lwIP - A Lightweight TCP/IP stack - Bugs: bug #49292, IP_HLEN seems to be incorrect in...
You are not allowed to post comments on this tracker with your current authentication level.
bug #49292: IP_HLEN seems to be incorrect in ip4.h
Submitter: | Michael Bechard <mtbowler416> | ||
Submitted: | Fri 07 Oct 2016 02:32:57 PM UTC | ||
Category: | IPv4 | Severity: | 3 - Normal |
Item Group: | Change Request | Status: | Invalid |
Privacy: | Public | Assigned to: | None |
Open/Closed: | Closed | Planned Release: | None |
lwIP version: | git head |
Fri 07 Oct 2016 02:37:41 PM UTC, comment #1: |
Dirk Ziegelmeier <dziegel> |
Fri 07 Oct 2016 02:32:57 PM UTC, original submission:
In file src/include/lwip/prot/ip4.h, IP_HLEN is defined as 20, and the comment right above this line says it should be the same as "sizeof(struct ip_hdr)". However, sizeof(struct ip_hdr) returns 28, which is also the value I get when counting up the bytes in the ip_hdr definition.
|
Michael Bechard <mtbowler416> |
No files currently attached
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 3 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2016-10-07 | dziegel | Status | None | Invalid | |
Open/Closed | Open | Closed | |||
2016-10-07 | mtbowler416 | Carbon-Copy | - | Added -email is unavailable- |
Powered by Savane 3.13-aa77.
Corresponding source code
Your port does not seem to correctly implement struct packing. Triple check this - sizeof(struct ip_hdr) MUST BE 20 - you won't get far without this working correctly.
See https://en.wikipedia.org/wiki/IPv4#Header
-> header (without options) is 20 bytes