mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-29 12:18:04 +01:00
Fix handle connection reset during session init
Patch to handle nmap version probes. Signed-off-by: Dhammika Pathirana <dhammika@gmail.com>
This commit is contained in:
committed by
Martin Sustrik
parent
56bdba592c
commit
c91bf25645
@@ -91,6 +91,10 @@ namespace zmq
|
||||
// bytes actually processed.
|
||||
inline size_t process_buffer (unsigned char *data_, size_t size_)
|
||||
{
|
||||
// Check if we had an error in previous attempt.
|
||||
if (unlikely (!(static_cast <T*> (this)->next)))
|
||||
return (size_t) -1;
|
||||
|
||||
// In case of zero-copy simply adjust the pointers, no copying
|
||||
// is required. Also, run the state machine in case all the data
|
||||
// were processed.
|
||||
|
||||
Reference in New Issue
Block a user