From 92ffb924556e43e3037273754ea94aabc72638a6 Mon Sep 17 00:00:00 2001 From: Sverker Eriksson Date: Wed, 30 Jan 2013 14:37:14 +0100 Subject: erts: Increase length of well formed header names from {packet,http} To ease matching of unrecognized header field names we convert them from case insensitive to the format Sec-Websocket-Version with capital letters only first and after hyphens. Earlier only header names up to 20 characters were converted to this format due to internal buffer limitation. Raising this limit to 50 is a pragmatic solution for existing long header names such as Sec-Websocket-Version, while valid header names longer than 50 characters are not very probable. --- erts/emulator/beam/packet_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'erts/emulator/beam') diff --git a/erts/emulator/beam/packet_parser.c b/erts/emulator/beam/packet_parser.c index 1e301e3593..7c9b2d444a 100644 --- a/erts/emulator/beam/packet_parser.c +++ b/erts/emulator/beam/packet_parser.c @@ -67,7 +67,7 @@ static int my_strncasecmp(const char *s1, const char *s2, size_t n) #define HTTP_HDR_HASH_SIZE 53 #define HTTP_METH_HASH_SIZE 13 -#define HTTP_MAX_NAME_LEN 20 +#define HTTP_MAX_NAME_LEN 50 static char tspecial[128]; -- cgit v1.2.3