1
0
mirror of https://github.com/openbsd/src.git synced 2025-01-10 06:47:55 -08:00

If tpcbench(8) is startet with -r0 it does not print statistics.

But there was still the header line.  Make -r0 really quiet and
document the feature.
OK deraadt@
This commit is contained in:
bluhm 2018-09-28 19:01:52 +00:00
parent 2271795444
commit 711342560b
2 changed files with 7 additions and 3 deletions

View File

@ -1,4 +1,4 @@
.\" $OpenBSD: tcpbench.1,v 1.24 2018/05/09 11:17:51 jmc Exp $
.\" $OpenBSD: tcpbench.1,v 1.25 2018/09/28 19:01:52 bluhm Exp $
.\"
.\" Copyright (c) 2008 Damien Miller <djm@mindrot.org>
.\"
@ -14,7 +14,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.Dd $Mdocdate: May 9 2018 $
.Dd $Mdocdate: September 28 2018 $
.Dt TCPBENCH 1
.Os
.Sh NAME
@ -114,6 +114,7 @@ In client mode the write buffer size is randomized up to the size specified via
.Fl B .
.It Fl r Ar interval
Specify the statistics interval reporting rate in milliseconds (default: 1000).
If set to 0, nothing is printed.
.It Fl S Ar space
Set the size of the socket buffer used for the test stream.
On the client this option will resize the send buffer;

View File

@ -1,4 +1,4 @@
/* $OpenBSD: tcpbench.c,v 1.58 2018/09/28 18:21:26 bluhm Exp $ */
/* $OpenBSD: tcpbench.c,v 1.59 2018/09/28 19:01:52 bluhm Exp $ */
/*
* Copyright (c) 2008 Damien Miller <djm@mindrot.org>
@ -281,6 +281,9 @@ print_tcp_header(void)
{
char **kv;
if (ptb->rflag == 0)
return;
printf("%12s %14s %12s %8s ", "elapsed_ms", "bytes", "mbps",
"bwidth");
for (kv = ptb->kvars; ptb->kvars != NULL && *kv != NULL; kv++)