From: Olivier Houchard Date: Wed, 1 May 2019 22:58:53 +0000 (+0200) Subject: BUG/MEDIUM: channels: Don't forget to reset output in channel_erase(). X-Git-Tag: v2.0-dev3~134 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=55071d30caab25aa2a147d5d4870c0b7ba460eef;p=thirdparty%2Fhaproxy.git BUG/MEDIUM: channels: Don't forget to reset output in channel_erase(). In channel_erase(), don't forget to set output to 0, otherwise the channel won't seem empty, when it really is, and that could lead to stream never closing properly. This should be backported to 1.9. --- diff --git a/include/proto/channel.h b/include/proto/channel.h index cf85058997..b2cd5c3745 100644 --- a/include/proto/channel.h +++ b/include/proto/channel.h @@ -545,6 +545,7 @@ static inline void channel_check_timeouts(struct channel *chn) static inline void channel_erase(struct channel *chn) { chn->to_forward = 0; + chn->output = 0; b_reset(&chn->buf); }