author | Alberto Bertogli
<albertito@gmail.com> 2007-10-11 07:32:47 UTC |
committer | Alberto Bertogli
<albertito@gmail.com> 2007-10-11 07:32:47 UTC |
parent | 00e67abb6b27389beccfdffc4ac123713fc982bc |
nmdb/sctp.c | +1 | -1 |
nmdb/tcp.c | +1 | -1 |
nmdb/tipc.c | +1 | -1 |
nmdb/udp.c | +1 | -1 |
diff --git a/nmdb/sctp.c b/nmdb/sctp.c index 7b02da3..bd74037 100644 --- a/nmdb/sctp.c +++ b/nmdb/sctp.c @@ -212,7 +212,7 @@ void sctp_recv(int fd, short event, void *arg) goto exit; } - if (rv < 2) { + if (rv < 8) { stats.net_broken_req++; goto exit; } diff --git a/nmdb/tcp.c b/nmdb/tcp.c index e511087..c1ed546 100644 --- a/nmdb/tcp.c +++ b/nmdb/tcp.c @@ -379,7 +379,7 @@ static void process_buf(struct tcp_socket *tcpsock, if (len >= 4) { totaltoget = * (uint32_t *) buf; totaltoget = ntohl(totaltoget); - if (totaltoget > (64 * 1024) || totaltoget <= 12) { + if (totaltoget > (64 * 1024) || totaltoget <= 8) { /* Message too big or too small, close the connection. */ goto error_exit; } diff --git a/nmdb/tipc.c b/nmdb/tipc.c index c821120..9d35a7f 100644 --- a/nmdb/tipc.c +++ b/nmdb/tipc.c @@ -196,7 +196,7 @@ void tipc_recv(int fd, short event, void *arg) goto exit; } - if (rv < 2) { + if (rv < 8) { stats.net_broken_req++; goto exit; } diff --git a/nmdb/udp.c b/nmdb/udp.c index 2adf54f..edf85b4 100644 --- a/nmdb/udp.c +++ b/nmdb/udp.c @@ -196,7 +196,7 @@ void udp_recv(int fd, short event, void *arg) goto exit; } - if (rv < 2) { + if (rv < 8) { stats.net_broken_req++; goto exit; }