[vlc-devel] [PATCH 1/2] aout: use vlc_atomic_rc_t

Alexandre Janniaux ajanni at videolabs.io
Fri Feb 21 19:13:58 CET 2020


Hi,

On Fri, Feb 21, 2020 at 07:00:29PM +0200, Rémi Denis-Courmont wrote:
> Le perjantaina 21. helmikuuta 2020, 16.14.34 EET
> quentin.chateau at deepskycorp.com a écrit :
> > From: Quentin Chateau <quentin.chateau at deepskycorp.com>
> >
> > ---
> >  src/audio_output/aout_internal.h | 3 ++-
> >  src/audio_output/output.c        | 7 ++++---
> >  2 files changed, 6 insertions(+), 4 deletions(-)
> >
> > diff --git a/src/audio_output/aout_internal.h
> > b/src/audio_output/aout_internal.h index 57b4f3264d..8b563012e2 100644
> > --- a/src/audio_output/aout_internal.h
> > +++ b/src/audio_output/aout_internal.h
> > @@ -25,6 +25,7 @@
> >
> >  # include <stdatomic.h>
> >
> > +# include <vlc_atomic.h>
> >  # include <vlc_viewpoint.h>
> >  # include "../clock/clock.h"
> >
> > @@ -97,7 +98,7 @@ typedef struct
> >      atomic_uint buffers_played;
> >      atomic_uchar restart;
> >
> > -    atomic_uintptr_t refs;
> > +    vlc_atomic_rc_t rc;
>
> This causes a potential unchecked overflow of the counter.
>
> No thanks.

It seems to me that it's an issue different than what the
patchset suggest.

Regards,
--
Alexandre Janniaux
Videolabs


More information about the vlc-devel mailing list