buglwIP - A Lightweight TCP/IP stack - Bugs: bug #45098, ip_addr_t type field not populated...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #45098: ip_addr_t type field not populated for socket address copies

Submitter:  James Smith <rallysmith>
Submitted:  Wed 13 May 2015 03:03:09 PM UTC
   
 
Category:  sockets/netconn Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  Fixed
Privacy:  Public Assigned to:  goldsimon
Open/Closed:  Closed Planned Release:  None
lwIP version:  git head

Thu 21 May 2015 01:52:02 PM UTC, comment #1: 

Fixed, thanks for reporting.

Simon Goldschmidt <goldsimon>
Group administrator
Wed 13 May 2015 03:03:09 PM UTC, original submission:  

When using a dual stack the type field was not being set when copying socket addresses, and so subsequent users of the ip_addr_t would more than likely treat an IPv6 address as a 32-bit IPv4 (since current macros default to IPv4 when type != IPADDR_TYPE_V6 and the uninitialised field could be anything depending on the underlying run-time).

Simple patch attached (since easier doing it in this dual stack only function than in the SOCKADDR#_TO_IP#ADDR_PORT macros).



James Smith <rallysmith>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #33999:  socket_ipaddr_type.patch added by rallysmith (606B - text/x-patch - Patch to set type field accordingly)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by rallysmith (Submitted the item)
  •  

    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 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2015-05-21 goldsimon StatusNone Fixed
        Assigned toNone goldsimon
        Open/ClosedOpen Closed
    2015-05-13 rallysmith Attached File- Added socket_ipaddr_type.patch, #33999

    Back to the top

    Powered by Savane 3.12.
    Corresponding source code