mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-05-30 16:30:29 -05:00
When receiving data, only pass up to the backend as much as we received.
[originally from svn r2572]
This commit is contained in:
parent
4ec4de4f8b
commit
6fbf5d8540
@ -467,7 +467,7 @@ void ot_recv(Actual_Socket s)
|
|||||||
do {
|
do {
|
||||||
o = OTRcv(s->ep, buf, sizeof(buf), &flags);
|
o = OTRcv(s->ep, buf, sizeof(buf), &flags);
|
||||||
if (o > 0)
|
if (o > 0)
|
||||||
plug_receive(s->plug, 0, buf, sizeof(buf));
|
plug_receive(s->plug, 0, buf, o);
|
||||||
if (o < 0 && o != kOTNoDataErr)
|
if (o < 0 && o != kOTNoDataErr)
|
||||||
plug_closing(s->plug, NULL, 0, 0); /* XXX Error msg */
|
plug_closing(s->plug, NULL, 0, 0); /* XXX Error msg */
|
||||||
} while (o > 0);
|
} while (o > 0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user