buglwIP - A Lightweight TCP/IP stack - Bugs: bug #49264, Crash Error when...

 
 

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

bug #49264: Crash Error when LWIP_SOCKET_OFFSET is in use

Submitter:  Arpit Agarwal <arpit_iitg>
Submitted:  Tue 04 Oct 2016 08:41:40 AM UTC
   
 
Category:  sockets/netconn Severity:  3 - Normal
Item Group:  Crash Error Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed Planned Release:  None
lwIP version:  git head

Tue 04 Oct 2016 10:35:23 AM UTC, comment #1: 

Thanks for reporting!

Dirk Ziegelmeier <dziegel>
Group administrator
Tue 04 Oct 2016 08:41:40 AM UTC, original submission:  

Crash Error occur in lwip_socket_drop_registered_memberships API due to LWIP_ASSERT condition fail when LWIP_SOCKET_OFFSET is in use.

The reason is the assert condition i.e. "sockets[s].conn" which still uses the same value as passed in the function. I think this should have been adjusted when LWIP_SOCKET_OFFSET is in use.

Similarly the socket descriptor value is not adjusted in lwip_socket_register_membership / lwip_socket_unregister_membership APIs.

I suggest the following fix in all the three APIs mentioned:

s -= LWIP_SOCKET_OFFSET; Code for fix

The Fix should be added in all the three API's at the very start, before any processing.


Arpit Agarwal <arpit_iitg>

 

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

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

    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-04 dziegel StatusNone Fixed
        Open/ClosedOpen Closed
    2016-10-04 arpit_iitg Carbon-Copy- Added -email is unavailable-

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code