]> git.proxmox.com Git - mirror_iproute2.git/commit
ss: Replace printf() calls for "main" output by calls to helper
authorStefano Brivio <sbrivio@redhat.com>
Tue, 12 Dec 2017 00:46:30 +0000 (01:46 +0100)
committerStephen Hemminger <stephen@networkplumber.org>
Tue, 12 Dec 2017 20:11:37 +0000 (12:11 -0800)
commit90351722cbaec74b075f568fb2cb28323b1b80c3
treec73f9eda21c85b4a883236c0452e3395cd58323b
parent9f1a9ae88862f0e5b1beef4bef582be0d8edf3d9
ss: Replace printf() calls for "main" output by calls to helper

This is preparation work for output buffering, which will allow
us to use optimal spacing and alignment of logical "columns".

The new out() function is just a re-implementation of a typical
libc's printf(), except that the return value of vfprintf() is
ignored as no callers use it. This implementation will be
replaced in the next patches to provide column width adjustment
and adequate spacing.

All printf() calls that output parts of the socket list are now
replaced by calls to out(). Output of summary and version is
excluded from this.

No functional differences here, output not affected.

Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Reviewed-by: Sabrina Dubroca <sd@queasysnail.net>
misc/ss.c