aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2017-10-29 01:12:42 +0200
committerMattias Andrée <maandree@kth.se>2017-10-29 01:12:42 +0200
commit4af9f0eea1670df1e1c11c6884b7bac34a3c1361 (patch)
tree9472391a26dbdc355d595c0f9b25a9c08ab89e36
parentReplace CMSG !/cred/prefix with !/cred/whoami (diff)
downloadsbus-4af9f0eea1670df1e1c11c6884b7bac34a3c1361.tar.gz
sbus-4af9f0eea1670df1e1c11c6884b7bac34a3c1361.tar.bz2
sbus-4af9f0eea1670df1e1c11c6884b7bac34a3c1361.tar.xz
Change buf size
Signed-off-by: Mattias Andrée <maandree@kth.se>
-rw-r--r--libsbus.h2
-rw-r--r--sbusd.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/libsbus.h b/libsbus.h
index 6ac4eed..cb078c8 100644
--- a/libsbus.h
+++ b/libsbus.h
@@ -4,7 +4,7 @@
#include <stdlib.h>
-#define LIBSBUS_BUFFER_SIZE ((3UL << 17) - 1UL)
+#define LIBSBUS_BUFFER_SIZE 409600
enum libsbus_packet_type {
LIBSBUS_UNKNOWN,
diff --git a/sbusd.c b/sbusd.c
index b2b8e2c..2da0fed 100644
--- a/sbusd.c
+++ b/sbusd.c
@@ -351,7 +351,7 @@ broadcast(const char *msg, size_t n)
static void
handle_message(struct client *cl)
{
- static char buf[3 << 17];
+ static char buf[409600 + 1];
int fd = cl->fd;
ssize_t r;