summaryrefslogtreecommitdiffstats
path: root/src/gzip.c
diff options
context:
space:
mode:
authorMark Riordan <mriordan@ipswitch.com>2011-06-10 16:00:06 -0500
committerAndreas Schneider <asn@cryptomilk.org>2011-08-09 20:13:41 +0200
commit8987bc53e067a746fd0596c585f73e7fa74526fe (patch)
tree8441bd5362a4759d858ee6c93ce2b364d13c409d /src/gzip.c
parent39802b31feb6c4fa9c2370781aa4b8f17478883c (diff)
downloadlibssh-8987bc53e067a746fd0596c585f73e7fa74526fe.tar.gz
libssh-8987bc53e067a746fd0596c585f73e7fa74526fe.tar.xz
libssh-8987bc53e067a746fd0596c585f73e7fa74526fe.zip
Fix "status -5 inflating zlib packet"
Signed-off-by: Mark Riordan <mriordan@ipswitch.com> Signed-off-by: Andreas Schneider <asn@cryptomilk.org> (cherry picked from commit 6c45d6dc0196a2846313b588c0e05996813ab3f8)
Diffstat (limited to 'src/gzip.c')
-rw-r--r--src/gzip.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gzip.c b/src/gzip.c
index cfea1e33..97c01e63 100644
--- a/src/gzip.c
+++ b/src/gzip.c
@@ -173,7 +173,7 @@ static ssh_buffer gzip_decompress(ssh_session session, ssh_buffer source, size_t
do {
zin->avail_out = BLOCKSIZE;
status = inflate(zin, Z_PARTIAL_FLUSH);
- if (status != Z_OK) {
+ if (status != Z_OK && status != Z_BUF_ERROR) {
ssh_set_error(session, SSH_FATAL,
"status %d inflating zlib packet", status);
ssh_buffer_free(dest);