]> git.ipfire.org Git - thirdparty/iproute2.git/commit
ss format bug
authorMike Saal <msaal@qacafe.com>
Wed, 26 Aug 2015 15:59:17 +0000 (11:59 -0400)
committerStephen Hemminger <shemming@brocade.com>
Wed, 9 Sep 2015 15:17:42 +0000 (08:17 -0700)
commit4fcfb6bc71f39039271b9f00d4044a9a2a97a0a3
tree1bfdf03c75340b28d95b70df358112657078ed90
parent9827fa57da0ee93b7573fd13865c56ab3c34afc8
ss format bug

Hi:

I found a formatting bug in the 4.1.1 ss command. The following line was
incorrectly output due to passing a negative length to printf() when
displaying the local address. In this instance hostapd does a "bind to
device" on cdreth0 and then does a udp "in address any" port 67 bind.
Please note the whitespace between the '*' and ' %cdreth0:67'

    'udp UNCONN 0 0 ** %cdreth0:67* *:* users:(("hostapd",pid=19241,fd=5))'

Attached is my patch for the bug fix, it might be prudent to add more
guard code looking for negative length format codes.

Sincerely, Mike
misc/ss.c