]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-program-client: Remove check for -2 returned from i_stream_read_more().
authorStephan Bosch <stephan.bosch@dovecot.fi>
Wed, 24 Jan 2018 20:48:07 +0000 (21:48 +0100)
committerStephan Bosch <stephan.bosch@dovecot.fi>
Fri, 26 Jan 2018 19:17:11 +0000 (20:17 +0100)
The stream must have space for at least 1 byte.

src/lib-program-client/program-client.c

index 3967996ac1035768a5f15f87329ccefc5541bc3f..61e577b21c2f0982fdf6cf37b2cdf0cb2d32c1fe 100644 (file)
@@ -351,11 +351,8 @@ void program_client_program_input(struct program_client *pclient)
                                return;
                        }
                } else {
-                       while ((ret =
-                               i_stream_read_more(input, &data, &size)) > 0 ||
-                              ret == -2) {
+                       while ((ret=i_stream_read_more(input, &data, &size)) > 0)
                                i_stream_skip(input, size);
-                       }
 
                        if (ret == 0)
                                return;