Re: [spice v7 1/3] dcc: handle preferred video codec message

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

 



Hi,

I forgot to reply to

On Thu, Feb 09, 2017 at 08:25:13AM +0100, Victor Toso wrote:
> On Tue, Feb 07, 2017 at 11:41:05AM +0100, Pavel Grunt wrote:
> > > +static int
> > > dcc_handle_preferred_video_codec_type(DisplayChannelClient *dcc,
> > > +         SpiceMsgcDisplayPreferredVideoCodecType *msg)
> > > +{
> > > +    gint i;
> > > +    GArray *client_codecs;
> > > +
> > > +    spice_return_val_if_fail(msg->num_of_codecs > 0, TRUE);
> > > +    spice_return_val_if_fail(msg->num_of_codecs <
> > > SPICE_VIDEO_CODEC_TYPE_ENUM_END, TRUE);
> >
> > I am afraid that spice_return may abort depending on the
> > configuration flags of spice-common.
> >
> > In this case it is not really desired (Client can have newer
> > protocol than the Server) so please use g_return_... Or don't use
> > the "end" condition - it is checked below anyway

True. If SPICE_DISABLE_ABORT is not defined, it should abort on critical
level of warnings (I thought we had removed that in the server too).

I'll switch to g_return_* as it seems safer.

        toso

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]