librsync  2.3.4
Functions
stats.c File Reference

stats reporting functions. More...

Include dependency graph for stats.c:

Go to the source code of this file.

Functions

int rs_log_stats (rs_stats_t const *stats)
 Write statistics into the current log as text. More...
 
char * rs_format_stats (rs_stats_t const *stats, char *buf, size_t size)
 Return a human-readable representation of statistics. More...
 

Detailed Description

stats reporting functions.

Todo:
Other things to show in statistics: number of input and output bytes, number of times we blocked waiting for input or output, number of blocks.

Definition in file stats.c.

Function Documentation

◆ rs_log_stats()

int rs_log_stats ( rs_stats_t const *  stats)

Write statistics into the current log as text.

See also
Stats
Trace output

Definition at line 31 of file stats.c.

◆ rs_format_stats()

char * rs_format_stats ( rs_stats_t const *  stats,
char *  buf,
size_t  size 
)

Return a human-readable representation of statistics.

The string is truncated if it does not fit. 100 characters should be sufficient space.

Parameters
statsStatistics from an encoding or decoding operation.
bufBuffer to receive result.
sizeSize of buffer.
Returns
buf.
See also
Stats

Definition at line 40 of file stats.c.