Le 01/08/2014 17:06, Carlos Alegria Galicia a écrit :
> Emmanuel,
>
> After debugging more the issue (and correcting the buffer reading code as
> you described), I finally found the root cause. When reading the header, I
> (incorrectly) assumed that the header should be contained in a single
> buffer. I was discarding some bytes of the header buffer that actually
> belong to the payload (the file being transmitted). This of course, is
> happening intermittently.

Yes, this is a common mistake : TCP fragmentation... You are not the
only one hit by this bus ;-)

Reply via email to