From dec0ea9e7063d93178b8a4292981ae225b7d4784 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sat, 23 Oct 2010 00:47:51 +0200 Subject: [PATCH] send_existing: don't tell parent to return when drained That will just cause unnecessary code execution. --- src/transport.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/transport.c b/src/transport.c index 7a9afaa..603f3d8 100644 --- a/src/transport.c +++ b/src/transport.c @@ -644,6 +644,9 @@ send_existing(LIBSSH2_SESSION *session, const unsigned char *data, /* the remainder of the package was sent */ p->ototal_num = 0; p->olen = 0; + *ret = 0; /* don't return */ + return LIBSSH2_ERROR_NONE; + } else if (rc < 0) { /* nothing was sent */