summary refs log tree commit diff
path: root/broadcast.c
diff options
context:
space:
mode:
Diffstat (limited to 'broadcast.c')
-rw-r--r--broadcast.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/broadcast.c b/broadcast.c
index c31112e..280a552 100644
--- a/broadcast.c
+++ b/broadcast.c
@@ -33,6 +33,8 @@
 #include <util.h>
 #endif
 
+#include "stream.h"
+
 static struct termios saveTerm;
 static void restoreTerm(void) {
     tcsetattr(STDERR_FILENO, TCSADRAIN, &saveTerm);
@@ -113,7 +115,7 @@ int main(int argc, char *argv[]) {
             if (writeSize < readSize) errx(EX_IOERR, "short write(%d)", remote);
 
             totalSize += readSize;
-            if (totalSize > 1024 * 1024) {
+            if (totalSize >= STREAM_SIZE) {
                 buf[0] = CTRL('L');
                 writeSize = write(pty, buf, 1);
                 if (writeSize < 0) err(EX_IOERR, "write(%d)", pty);