Files
wlan-ap/feeds/ucentral/rtty/patches/300-throttle.patch
John Crispin ea95356ebd rtty: improve patch indenting
Newer version of GCC complained about inconsistent indenting.

Signed-off-by: John Crispin <john@phrozen.org>
2023-03-15 09:56:09 +01:00

32 lines
787 B
Diff

Index: rtty-7.1.4/src/rtty.c
===================================================================
--- rtty-7.1.4.orig/src/rtty.c
+++ rtty-7.1.4/src/rtty.c
@@ -36,6 +36,8 @@
#include "utils.h"
#include "command.h"
+#include <poll.h>
+
extern int force_exit;
extern int connected;
@@ -84,7 +86,7 @@ static void pty_on_read(struct ev_loop *
struct tty *tty = container_of(w, struct tty, ior);
struct rtty *rtty = tty->rtty;
struct buffer *wb = &rtty->wb;
- static uint8_t buf[4096];
+ static uint8_t buf[32* 1024];
int len;
while (1) {
@@ -394,6 +396,8 @@ static void on_net_write(struct ev_loop
if (buffer_length(&rtty->wb) < 1)
ev_io_stop(loop, w);
+
+ poll(NULL, 0, 100);
}
static void on_net_connected(int sock, void *arg)