buglwIP - A Lightweight TCP/IP stack - Bugs: bug #33079, Formatting error in debug string...

 
 

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

bug #33079: Formatting error in debug string in sockets.c

Submitter:  David Empson <dempson>
Submitted:  Thu 14 Apr 2011 11:30:52 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:  CVS Head

Thu 21 Apr 2011 05:22:38 AM UTC, comment #1: 

Fixed, thanks for reporting.

Simon Goldschmidt <goldsimon>
Group administrator
Thu 14 Apr 2011 11:30:52 PM UTC, original submission:  

There is a minor error in one debug string in sockets.c.

Lines 897 and 898 read:

  LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_sendto(%d, data=%p, short_size=%d"U16_F", flags=0x%x to=",
              s, data, short_size, flags));

The 'short_size=%d"U16_F"' part has an extraneous 'd' after the '%', which will result in this field being printed using the format specifier %d followed by the literal text of the platform specific U16_F macro.

Assuming none of the other format specifiers need to use platform-specific macros, the correct version should be:

  LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_sendto(%d, data=%p, short_size=%"U16_F", flags=0x%x to=",
              s, data, short_size, flags));


David Empson <dempson>

 

(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 goldsimon (Posted a comment)
  • -email is unavailable- added by dempson (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 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2011-04-21 goldsimon StatusNone Fixed
        Assigned toNone goldsimon
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code