summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
authorDastgir <dastgirpojee@rocketmail.com>2015-12-17 13:43:00 +0530
committerDastgir <dastgirpojee@rocketmail.com>2015-12-17 13:44:03 +0530
commit96759fdd5dbc222c3d693f68c85a98b5557bf405 (patch)
tree9cecd9329959cd0b6fbc0e6d6aac9be3854a2e7a /src/common
parent63abf092ab36d39ee4acc67d3c90091cb12b16f1 (diff)
downloadhercules-96759fdd5dbc222c3d693f68c85a98b5557bf405.tar.gz
hercules-96759fdd5dbc222c3d693f68c85a98b5557bf405.tar.bz2
hercules-96759fdd5dbc222c3d693f68c85a98b5557bf405.tar.xz
hercules-96759fdd5dbc222c3d693f68c85a98b5557bf405.zip
Update max packet size according to client date
Diffstat (limited to 'src/common')
-rw-r--r--src/common/socket.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/common/socket.c b/src/common/socket.c
index 362fe78db..88d35e57a 100644
--- a/src/common/socket.c
+++ b/src/common/socket.c
@@ -238,7 +238,11 @@ fd_set readfds;
// Maximum packet size in bytes, which the client is able to handle.
// Larger packets cause a buffer overflow and stack corruption.
-static size_t socket_max_client_packet = 24576;
+#if PACKETVER >= 20131223
+static size_t socket_max_client_packet = 0xFFFF;
+#else
+static size_t socket_max_client_packet = 0x6000;
+#endif
#ifdef SHOW_SERVER_STATS
// Data I/O statistics