From 0c837cdc7723d1f02d1f72209a6433ee547075e1 Mon Sep 17 00:00:00 2001 From: Olaf Bergmann Date: Sat, 11 Nov 2017 10:06:16 +0100 Subject: [PATCH] pdu.h: increase Max-Message-Size by 256 B To allow for 8 MiB payloads, the maximum message size value for TCP has been increased by 256 B option space. --- include/coap/pdu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/coap/pdu.h b/include/coap/pdu.h index d0bb73ab..cd1c8c59 100644 --- a/include/coap/pdu.h +++ b/include/coap/pdu.h @@ -47,7 +47,8 @@ struct coap_session_t; #if defined(WITH_CONTIKI) || defined(WITH_LWIP) #define COAP_DEFAULT_MAX_PDU_RX_SIZE (COAP_MAX_MESSAGE_SIZE_TCP16+4) #else -#define COAP_DEFAULT_MAX_PDU_RX_SIZE (8*1024*1024) +/* 8 MiB max-message-size plus some space for options */ +#define COAP_DEFAULT_MAX_PDU_RX_SIZE (8*1024*1024+256) #endif #endif /* COAP_DEFAULT_MAX_PDU_RX_SIZE */