diff options
author | Pierre Ossman <ossman@cendio.se> | 2020-05-16 12:14:43 +0200 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2020-05-21 11:34:22 +0200 |
commit | d8b432cf26b835e52a087de9747a51d2401c07e3 (patch) | |
tree | 69435e528dba1e72115cb17babde42254a9de116 /common/rdr/BufferedOutStream.h | |
parent | c2bbdb573d546eb88539d1204b84cb48d910191a (diff) | |
download | tigervnc-d8b432cf26b835e52a087de9747a51d2401c07e3.tar.gz tigervnc-d8b432cf26b835e52a087de9747a51d2401c07e3.zip |
Dynamically allocate stream buffers
This allows us to handle peaks in input and output streams gracefully
without having to block processing.
Diffstat (limited to 'common/rdr/BufferedOutStream.h')
-rw-r--r-- | common/rdr/BufferedOutStream.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/common/rdr/BufferedOutStream.h b/common/rdr/BufferedOutStream.h index 8e3229d5..05727f6e 100644 --- a/common/rdr/BufferedOutStream.h +++ b/common/rdr/BufferedOutStream.h @@ -24,6 +24,8 @@ #ifndef __RDR_BUFFEREDOUTSTREAM_H__ #define __RDR_BUFFEREDOUTSTREAM_H__ +#include <sys/time.h> + #include <rdr/OutStream.h> namespace rdr { @@ -53,6 +55,9 @@ namespace rdr { size_t offset; U8* start; + struct timeval lastSizeCheck; + size_t peakUsage; + protected: U8* sentUpTo; |