From 1c3f35ffeb032ae4e8ce939eca8e5e9466b046a9 Mon Sep 17 00:00:00 2001 From: pranomostro Date: Tue, 22 Nov 2016 17:56:50 +0100 Subject: Fix issue that prevents correct sending of INCOMPLETE buffers. f->av.state & INCOMPLETE was evaluated as 8, which made the third test always false. --- ratox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ratox.c b/ratox.c index d5ca466..daf40ef 100644 --- a/ratox.c +++ b/ratox.c @@ -495,7 +495,7 @@ sendfriendcalldata(struct friend *f) return; } else if (n < 0) { return; - } else if (n == (framesize * sizeof(int16_t) - (f->av.state & INCOMPLETE) * f->av.n)) { + } else if (n == (framesize * sizeof(int16_t) - (f->av.state & INCOMPLETE ? f->av.n : 0))) { f->av.state &= ~INCOMPLETE; f->av.n = 0; } else { -- cgit v1.2.3