Re: [spice-server 2/3] Fix some small red_channel_client_msg_sent() regression

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Tue, Apr 11, 2017 at 10:53:17AM -0500, Jonathon Jongsma wrote:
> On Tue, 2017-04-11 at 11:58 +0200, Christophe Fergeau wrote:
> > Commit 0239dfa added a call to red_channel_client_clear_sent_item()
> > to
> > red_channel_client_msg_sent(). One of the thing that
> > red_channel_client_msg_sent() does is to reset rcc->priv-
> > >send_data.blocked
> > to FALSE.
> > 
> > This means that the preexisting check for this value in
> > red_channel_client_msg_sent() became dead code as it comes right
> > after
> > the call to red_channel_client_clear_sent_item():
> > 
> >     red_channel_client_clear_sent_item(rcc);
> >     if (red_channel_client_is_blocked(rcc)) {
> >         [...]
> >     }
> > 
> > This commit moves the red_channel_client_clear_sent_item(); right
> > after
> > this check in order to avoid checking for a value which will always
> > be
> > FALSE.
> 
> Interesting. How did you find this? Did it cause some problem that you
> observed?

Nope, just code inspection, as there was another occurences in that
function of testing for a blocked channel, which cannot be true, so I
noticed this one as well.

Christophe

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]